Website basedir

Discussion in 'Installation/Configuration' started by usersince1900, Apr 3, 2020.

  1. usersince1900

    usersince1900 New Member

    Hello,
    I have lost access to my sites after changing the location in the Website basedir settings on the server config page. How do I revert back to original settings to regain access? Any help will be much appreciated.
    Regards,
    upload_2020-4-3_12-39-43.png
     
  2. Jesse Norell

    Jesse Norell Well-Known Member Staff Member Howtoforge Staff

    I've not tried, but you can't simply change it back and Resync websites?

    I would try to bind mount the old location at the new location, which should get everything working, then change everything back to what it was.
     
  3. usersince1900

    usersince1900 New Member

    Thanks for the reply. No, I have lost the connectivity. Nothing loads now.
     
  4. Taleman

    Taleman Well-Known Member HowtoForge Supporter

    Can you still use ISPConfig Panel?
    What @Jesse Norell suggested means logging in as root from console or SSH, and bind mounting from command line.
    If ISPConfig Panel still works, change the directories back as they were and in Panel use Tools | Sync Tools | Resync to fix the websites.
     
  5. usersince1900

    usersince1900 New Member

    Thank you very much for your reply. ISPConfig is a wonderful software and very powerful. My huge gratitude to the developers and the community for providing this software and support for free. I have come across this tutorial written by @till while searching for the solution:
    https://www.howtoforge.com/use_moun...ctory_of_a_ispconfig_server_to_a_new_location
    I am fairly new to Linux and this project is an educational one. I decided to restore from an old backup before reading your reply. However, if I understand it correctly you are suggesting to log in to the server cli and:

    mount --bind /new/location/i/changed /var/www
    and that should have brought back the GUI?
    This may be a good idea to include a warning in the future updates of ISPConfig to take caution if changing something breaks the system.
     
  6. nhybgtvfr

    nhybgtvfr Well-Known Member HowtoForge Supporter

    well, to be fair, changing the whose systems website basedir, in a piece of software that is designed for hosting websites, which itself uses that same basedir you're changing, it should be quite obvious that it has the potential to fubar everything, even without putting a warning there. ;)

    this should really be a lesson for everyone. if you're planning on making configuration changes to your system, create a test copy of the system first and test it there first, never test changes on a live system.:D
     
  7. Steini86

    Steini86 Active Member

    Delete all symlink starting with "100-" in /etc/apache2/sites-enabled (rm /etc/apache2/sites-enabled/100*). Then restart apache. This should bring back your interface. Then undo the changes and go to Tools -> Resync -> Websites to recreate the links.
     

Share This Page