0

So, yesterday I updated ubuntu and that included an nginx update, the process warned about diffs/changes to the default file under sites-available, I reviewed the changes and prepared a new file which included the updates and my personal settings, I noticed the default directory to store projects was now /var/www/html/ instead of /usr/share/nginx/html/ and I actually had been thinking about making that very same change myself so I agreed and included that change in my new default configuration file, which I saved to ~/Desktop temporarily, so I wouldn't interfere with the update process.

After I was finished editing my new file I agreed to replace the existing one as asked by the update prompt/process.
The updating process continued only to state a failure a few seconds later, the error stated something about failed to decompress package, I thought it would be fixed by attempting to update the system again so I tried but the update manager stated "there are no updates to install" (needless to say I got a bit suspicious but well, I just restarted the OS as asked).
After rebooting I backed up and replaced the default file with my newly created one and moved all contents of /usr/share/nginx/html/ to /var/www/html/
Oddly enough, going to localhost didn't work but going to any other project stored on subdirectories worked fine, so I didn't care too much for the moment.

Here's where it gets interesting (well a bit interesting, at least).
Today I installed a non related package and suddenly the package manager tried to include some nginx changes in the process by executing a script and failed to do so.
gif of package manager tty process showing the previously stated error

NOTE: Here's a pastebin of the terminal's output (before and after the fix): http://pastebin.com/pYv7yKrz

0

I noticed this line:

cp: cannot stat `/usr/share/nginx/html/index.html': No such file or directory`

So I figured maybe just adding the previous index.html file (located now on /var/www/html/) to the old path (/usr/share/nginx/html/) would help the script execute without throwing an exception, and it did work. gif of package manager tty process showing the previously stated success

http://localhost is working fine now. nginx's default welcome message showing on browser

2
  • I'm glad you solved your own problem. However, please do not add a new question to this answer thread. Instead, ask a new question and link this one for relevance. Thank you! – Kaz Wolfe Nov 3 '14 at 23:50
  • that's exactly what I did – JorgeArtware Nov 4 '14 at 0:04

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.