有些朋友找yqf.me安装了DA面板,但是拿到手里后,傻眼了,不会使用。其实DA还是蛮实用的,仔细琢磨下,不是很难。点上图的右上角:代理级别。再点下图中的管理预设值。
点上图的添加预设值。
如果自己使用的话,可以都设置成无限制。
再回到管理级,点添加用户。
填下用户名,邮箱,密码,域名,选择用户预设值,然后提交,就算创建好虚拟主机了。
至于如何使用DA搭建网站,请参看一下教程:
有些朋友找yqf.me安装了DA面板,但是拿到手里后,傻眼了,不会使用。其实DA还是蛮实用的,仔细琢磨下,不是很难。点上图的右上角:代理级别。再点下图中的管理预设值。
点上图的添加预设值。
如果自己使用的话,可以都设置成无限制。
再回到管理级,点添加用户。
填下用户名,邮箱,密码,域名,选择用户预设值,然后提交,就算创建好虚拟主机了。
至于如何使用DA搭建网站,请参看一下教程:
很开心,经过不懈的努力,经过三番五次的和DA官方沟通,重要给yqf.me开通在线修改DA授权的权限了,这样的好处是,网友在yqf.me购买的DA授权,如果将来换IP和系统了,只需要给我发个邮件或者QQ或者旺旺等各种方式告诉我,我在线的话,可以立即变更DA授权。 Continue reading
自从安装了DA面板后,Brute Force Attack暴力破解DA后台密码就没有停止过,或许见多了就不怪了,但是老是收到诸如此类的信息:Brute-Force Attack detected in service log from IP(s) 106.187.43.249,总不是一件让人很愉快的事儿。
directadmin官方有教程,如何屏蔽ip阻止Brute ForceAttack
http://help.directadmin.com/item.php?id=380
以下我将官方的教程汉化下:
1)第一步,配置iptables,让block_ip.sh生效,DA官方的iptables文件适用于CentOS/Fedora,目前没有在Debian或者FreeBSD上测试,或许支持,或许不知道debian/FreeBSD。
cd /etc/init.d
mv iptables iptables.backup
wget http://files.directadmin.com/services/all/iptables
chmod 755 iptables*** 注意,ipables默认开启的ssh端口是22,如果你的ssh端口不是22,请手动修改iptables设置。
*** 注意,ipables默认开启的ssh端口是22,如果你的ssh端口不是22,请手动修改iptables设置。启动iptables:
/etc/init.d/iptables restart
2) 第二步,安装block_ip.sh脚本,block_ip.sh格式可以在found here找到 .
cd /usr/local/directadmin/scripts/custom
wget http://files.directadmin.com/services/all/block_ip.sh
wget http://files.directadmin.com/services/all/show_blocked_ips.sh
wget http://files.directadmin.com/services/all/unblock_ip.sh
chmod 700 block_ip.sh show_blocked_ips.sh unblock_ip.sh
3)创建blocked_ips文本:
touch /root/blocked_ips.txt
touch /root/exempt_ips.txt
去DA后台操作下Home–>Brute Forece Monitor–>IP info–>Blcok this IP.
4)自动封IP:
vi /usr/local/directadmin/scripts/custom/brute_force_notice_ip.sh
添加内容:
#!/bin/sh
SCRIPT=/usr/local/directadmin/scripts/custom/block_ip.sh
ip=$value $SCRIPT
exit $?;
chmod 700 brute_force_notice_ip.sh
以下是FreeBSD相关:
If you’re running FreeBSD with ipfw, you’d skip steps 2 and 3, and instead, add the following code to the file:
/usr/local/directadmin/scripts/custom/block_ip.sh
#!/bin/sh
echo “Blocking $ip with ipfw …<br>”;
ipfw add deny ip from $ip to any
exit $?
and don’t forget to chmod the block_ip.sh to 755.
User yqf1 created |
|
|
|
Details Unix User created successfully Error with system Quotas Domain Created Successfully User added to ssh config file. |
2016年3.14日更新。好几年的问题,其实是Directadmin的一个bug,今天帮客户安装DA面板,系统是centos 6.x 64位,依然还是存在这个问题,耐心看了下官方的教程。简单处理下就可以了。
加入我们就一个盘,根目录是/,我们df -h是可以查看磁盘规划的。
我们执行 /usr/sbin/repquota / ,如果磁盘配额生效的,那会显示类似下面的:
[root@da182 ~]# /usr/sbin/repquota /
*** Report for user quotas on device /dev/xvda1
Block grace time: 7days; Inode grace time: 7days
Block limits File limits
User used soft hard grace used soft hard grace
———————————————————————-
root — 1985016 0 0 70212 0 0
daemon — 8 0 0 3 0 0
mail — 96 0 0 35 0 0
ftp — 1656 0 0 103 0 0
abrt — 24 0 0 4 0 0
haldaemon — 8 0 0 2 0 0
ntp — 8 0 0 2 0 0
named — 40 0 0 10 0 0
apache — 32 0 0 8 0 0
diradmin — 209608 0 0 3434 0 0
mysql — 31712 0 0 131 0 0
majordomo — 356 0 0 34 0 0
webapps — 73604 0 0 6126 0 0
dovecot — 0 0 0 8 0 0
admin — 132 0 0 33 0 0
问题就是他不显示正常的磁盘配额,所以我们要修改下配置:
/sbin/quotaoff -a; /sbin/quotacheck -avugm; /sbin/quotaon -a;
先执行下这个,如果还是报错。
那就修改下/etc/fstab设置,vi /etc/fstab
类似,添加红色的,usrquota,grpquota就可以了。
# Device Mountpoint FStype Options Dump Pass#
/dev/ad0s1a / ext3 rw,usrquota,grpquota 1 1
/dev/ad0s1e /tmp ext3 rw 2 2
proc /proc procfs rw 0 0
然后重启下机器。
然后再执行下:
/sbin/quotaoff -a; /sbin/quotacheck -avugm; /sbin/quotaon -a;
会看见磁盘配额生效了:
[root@da182 ~]# /sbin/quotaoff -a; /sbin/quotacheck -avugm; /sbin/quotaon -a;
quotacheck: Your kernel probably supports journaled quota but you are not using it. Consider switching to journaled quota to avoid running quotacheck after an unclean shutdown.
quotacheck: Scanning /dev/xvda1 [/] done
quotacheck: Cannot stat old user quota file //aquota.user: No such file or directory. Usage will not be substracted.
quotacheck: Cannot stat old group quota file //aquota.group: No such file or directory. Usage will not be substracted.
quotacheck: Cannot stat old user quota file //aquota.user: No such file or directory. Usage will not be substracted.
quotacheck: Cannot stat old group quota file //aquota.group: No such file or directory. Usage will not be substracted.
quotacheck: Checked 11747 directories and 73601 files
quotacheck: Old file not found.
quotacheck: Old file not found.
===========================
[root@da182 ~]# /usr/sbin/repquota /
*** Report for user quotas on device /dev/xvda1
Block grace time: 7days; Inode grace time: 7days
Block limits File limits
User used soft hard grace used soft hard grace
———————————————————————-
root — 1985016 0 0 70212 0 0
daemon — 8 0 0 3 0 0
mail — 96 0 0 35 0 0
ftp — 1656 0 0 103 0 0
abrt — 24 0 0 4 0 0
haldaemon — 8 0 0 2 0 0
ntp — 8 0 0 2 0 0
named — 40 0 0 10 0 0
apache — 32 0 0 8 0 0
diradmin — 209608 0 0 3434 0 0
mysql — 31712 0 0 131 0 0
majordomo — 356 0 0 34 0 0
webapps — 73604 0 0 6126 0 0
dovecot — 0 0 0 8 0 0
admin — 132 0 0 33 0 0
各方面正常以后,再执行下:
echo “action=tally&value=all” >> /usr/local/directadmin/data/task.queue
就ok了。
Centos安装DirectAdmin教程:
1、安装DA需要纯净的系统,之前有些朋友安装DA报错,请先执行:yum remove httpd* mysql* php*
2、预安装DA需要的环境:
yum install wget gcc gcc-c++ flex bison make bind bind-libs bind-utils openssl openssl-devel perl quota libaio libcom_err-devel libcurl-devel gd zlib-devel zip unzip libcap-devel cronie bzip2 db4-devel cyrus-sasl-devel perl-ExtUtils-Embed autoconf automake libtool
3、从官方下载setup.sh安装脚本安装DirectAdmin面板:
wget http://www.directadmin.com/setup.sh
chmod 755 setup.sh
./setup.sh
4、DA面板安装过程截图:
根据屏幕提示输入Client ID,License ID,以及主机名。
会核实是否是授权IP,以及DA授权绑定的linux发行版。
选择DA面板将要安装的PHP/Apache等,默认推荐的,选3即可。
开始搜索最快的下载镜像,进入DA编译安装过程。
5、DA面板安装完毕:
directory /home/tmp created
directory /usr/local/directadmin/data/sessions created
directory /etc/virtual created
directory /var/spool/virtual created
directory ./data/admin/ips created
directory ./data/admin/packages created
file ./data/admin/packages.list created
ip.list written successfully
./data/admin/login.hist written successfully
./data/admin/next_ticket.number written correctly
./data/admin/services.status written successfully
tickets.list written successfully
Admin user created
## INSTALL_COMPLETE
## ACCOUNT_INFO
The following information has been set:
Admin username: admin
Admin password: abcdefg
Admin email: admin@abc.yqf.me
Server IP: 50.116.xx.xxx
Server Hostname: abc.yqf.me
To login now, follow this link:
http://50.116.xx.xxx:2222
and enter your Admin username and password when prompted.
You should now visit http://admin.site-helper.com and http://www.directadmin.com/newinstall.html to learn how to get started.
Thank you for using DirectAdmin. Should you have any questions, don’t hesitate to contact us at support@directadmin.com
## REPORT_END
Permissions set
System Security Tips:
http://help.directadmin.com/item.php?id=247
6、模板安装。模板安装好后,进入reseller级别,选中你要的模板,点应用所有,应用自己,就ok了。