Plesk Otomatik Yetkilendirme

Plesk panellerinizde taşıma sonrası veya kullanım hatasından dolayı vhosts dizinlerinizde yetki problemi yaşayabilirsiniz.

Aşağıdaki kodu linux sunucunuza root olarak login olduktan sonra yeni bir .sh dosyası yaratarak içine yazmanız ve daha sonra çalıştırmanız yeterlidir.

#!/bin/sh
#
# rebuild vhost permisions for Parallels plesk 9 on centos 5
# arjen [AT] hostingondemand.nl
#
for i in `cat /etc/passwd | grep /var/www/vhosts`; do
#
path=`echo $i | cut -d: -f6`
user=`echo $i | cut -d: -f1`
echo $user : $path
#
#
chown -R -f $user:psacln $path/httpdocs/* >> /dev/null
chown -R -f $user:psacln $path/httpdocs/.* >> /dev/null
chown -R -f $user:psacln $path/httpsdocs/* >> /dev/null
chown -R -f $user:psacln $path/httpsdocs/.* >> /dev/null
chown -f $user:psaserv $path/httpdocs >> /dev/null
chown -f $user:psaserv $path/httpsdocs >> /dev/null
chown -f $user:psaserv $path/cgi-bin >> /dev/null
chown -f $user:psaserv $path/anon_ftp >> /dev/null
chown -f $user:psaserv $path/statistics >> /dev/null
chown -f $user:psaserv $path/statistics/anon_ftpstat >> /dev/null
chown -f $user:psacln $path/statistics/anon_ftpstat/* >> /dev/null
chown -f $user:psaserv $path/statistics/ftpstat >> /dev/null
chown -f $user:psacln $path/statistics/ftpstat/* >> /dev/null
chown -f $user:psaserv $path/statistics/logs >> /dev/null
chown -f $user:psacln $path/statistics/logs/* >> /dev/null
chown -f $user:psaserv $path/statistics/webstat >> /dev/null
chown -f $user:psacln $path/statistics/webstat/* >> /dev/null
chown -f $user:psaserv $path/statistics/webstat-ssl >> /dev/null
chown -f $user:psacln $path/statistics/webstat-ssl/* >> /dev/null
chown -f $user:psaserv $path/pd >> /dev/null
chown -f apache:apache $path/pd/* >> /dev/null
chown -f $user:psaserv $path/conf >> /dev/null
chown -f root:root $path/conf/* >> /dev/null
#subdomains
chown -f $user:psaserv $path/subdomains/*/cgi-bin >> /dev/null
chown -f $user:psaserv $path/subdomains/*/httpdocs >> /dev/null
chmod -f 755 $path/subdomains/*/cgi-bin >> /dev/null
#
done
#

yazilan makaleler izinsiz kopyalanamaz aksi taktirde dmca tarafindan gerekli islemler baslatilacaktir.