Access Website Without Domain & Files Ownership

Discussion in 'ISPConfig 3 Priority Support' started by nvidian, May 19, 2015.

  1. nvidian

    nvidian Member

    Hi, I plan to migrate all my websites to new ispconfig NGINX server. I already copy the website's files & database, rename database name to match ispconfig database name etc - but I want to make sure that it work before I change DNS point to new IP (minimal downtime). Is there some way to access all websites before I point DNS to new IP - wiithout using vhost trick ?

    Also, is it necessary to chown website's files & folder to web X username & client X group ? Can I just rename files & folder to www-data ? Is quota system (disk & bandwidth) still working if I dont set ownership to web X & client X ?

    Thank you
  2. Croydon

    Croydon ISPConfig Developer ISPConfig Developer

    In short, because I am on mobile:

    To test websites, add entries with that website in your local host file (on unix it is /etc/hosts).

    Yes, you have to chown all webs to their owners, unless you are using modphp (which is a security risk).
    HDD quota will not work when using www-data. Traffic quota will.

  3. nvidian

    nvidian Member

    Thanks you Manus. Do you have short shell command to auto chown to match its user & group name ? It will be better if ispconfig has this command in cron.
    It will be A LOT of work to migrate , but I see a better future with ISPconfig :)
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    this would be bad if it exist as it would destroy custom ownership and permission settings.
  5. Croydon

    Croydon ISPConfig Developer ISPConfig Developer

    Could be quite dangerous to use but if you want to risk it:
    cd /var/www/clients
    for C in client* ; do
      cd $C;
      for W in web* ; do
          chattr -i $W ;
          chown -R ${W}:${C} $W/web $W/private $W/tmp $W/webdav $W/cgi-bin ;
          chown -R root:root $W/web/stats;
          chattr +i $W;
      cd ..;
  6. nvidian

    nvidian Member

    Thanks a lot Manus. I already chown per web folder manually. But I'll keep this for future use. Thanks again.

Share This Page