I've accidentally deleted the files in /var/log

quats

Member
Mar 11, 2008
6
0
51
I have accidentally deleted the files in /var/logs folder and now I'm not receiving any mail. I have tried to reinstall cpanel by using the update cpanel feature and selected the force reinstall option.

It recreated some of the files but not all is there a way to get the files in /var/log recreated.
 

rpmws

Well-Known Member
Aug 14, 2001
1,802
9
318
back woods of NC, USA
I don't know the names of the files i need to recreate
you may be able to get them to create themselves by restarting syslogd, pop ssh exim cron ... try restarting exim /scripts/restartsrv_exim and see if the exim_mainlog comes back. do this for all the services ...or you could try and reboot and you may find most come back.

I just tested my theory and found that:
/scripts/restartsrv_exim recreates exim logs

actually thsi may get much of that stuff back for you.
/scripts/restartsrv_syslogd
 
Last edited:

quats

Member
Mar 11, 2008
6
0
51
Thanks for that,

Mail working again now, most of the files were recreated when I done the update but it appears to exim log files were not created, I ran the second command you gave and this solved it.

Thanks again