0

I have a web server set up using the www directory with a whole bunch of files that have not received their monthly backup. I've done a ton of work so I'd like to not restart.

I then set up an e-mail server that would create Maildir, etc. for e-mail on admin, etc.

Then tried to set up ftp for when I'm away and followed the accepted answer for

Basic Ubuntu FTP Server

Which worked fine but in the process all my files in www disappeared! I'm assuming its the combination with the mail server creating directories but what I really need to know is how to get the files back!

edit: My problem has been solved by me forgetting to close gedit. Thank god! On the other hand this is rather odd and supposedly not because of the adduser behavior. Most likely the default behavior of an e-mail server. But I've heard no mention of it being an issue. So it must be the combination. If it didn't delete the files they should have gone somewhere though and photorec should have been able to recover something that was only missing its link in the file table. Still a puzzle on multiple fronts.

1 Answers1

0

It's hard to tell, but I think the /var/www directory was recreated (rm -rf then mkdir). It's hard to tell because I'm not sure exactly what adduser does when you add a user with a new home directory that already exists.

You wouldn't want to give a user a new home cluttered with files. I think adduser scrapped your work.

A program like photorec might be able to save you, but if you have to recreate everything it will be good practice and you'll learn not to use adduser on a directory you want to keep.

This is just a theory.

noel
  • 304
  • 1
  • 14