SOLVED Deleted files under /tmp

Elizabeta

Well-Known Member
Mar 21, 2018
248
33
28
Mostar
cPanel Access Level
Root Administrator
Hello,

I have cPanel&WHM version 72.0.11. I have deleted accidentally everything under /tmp.

We have another cPanel on other machine and I see that in that directory there are:


drwxrwxrwt. 26 root root 4096 Sep 14 14:10 .
dr-xr-xr-x. 20 root root 4096 Aug 23 10:28 ..
drwx------ 2 root root 4096 Jul 13 09:46 5577.XML_API___GET_UPDATE_AVAILABILITY__.2d52f8a2.tmp
drwx------ 2 root root 4096 Jul 13 09:46 5579._API___GET_CURRENT_LTS_EXPIRATION_STATUS__.c47b025c.tmp
drwx------ 2 root root 4096 Jul 13 09:46 5736.XML_API___GET_UPDATE_AVAILABILITY__.1613af01.tmp
drwx------ 2 root root 4096 Jul 13 09:46 5797.XML_API___GET_UPDATE_AVAILABILITY__.0ee974e1.tmp
drwxr-xr-x 2 abrt abrt 4096 Aug 16 18:31 abrt
drwxr-xr-x 3 root root 45056 Jun 14 09:47 Agent-RedHat_EL7-10.0.0-2856.x86_64
drwxrwxrwt 2 root root 4096 Aug 23 10:28 .font-unix
drwxrwxr-x 4 root root 4096 Jun 20 13:24 .gxsetup
drwxr-xr-x. 2 cpanelsolr cpanelsolr 4096 Aug 23 10:28 hsperfdata_cpanelsolr
drwxr-xr-x 2 root root 4096 Aug 23 10:27 hsperfdata_root
drwxrwxrwt 2 root root 4096 Aug 23 10:28 .ICE-unix
drwxr-xr-x 2 cpanelsolr cpanelsolr 4096 Aug 23 10:28 jetty-127.0.0.1-8984-webapp-_solr-any-5460422071335892376.dir
drwxrwxrwx 2 root root 4096 Jul 13 13:37 locks
drwx------ 2 root root 16384 Mar 21 15:46 lost+found
-rw-r--r-- 1 root root 73 Aug 16 18:31 lua_5VN800
lrwxrwxrwx 1 root root 30 Sep 14 14:10 mysql.sock -> ../../var/lib/mysql/mysql.sock

drwx------ 3 root root 4096 Jun 11 14:01 spamd-5991-init
-rw------- 1 cpanelsolr cpanelsolr 165 Aug 23 10:28 start_2363584886905542465.properties
drwx------ 3 root root 4096 Aug 23 10:28 systemd-private-498ec864aba84a1386677fd745b360c5-cups.service-H5niYL
drwx------ 3 root root 4096 Aug 23 10:28 systemd-private-498ec864aba84a1386677fd745b360c5-cups.service-QWTyvU
drwx------ 3 root root 4096 Aug 23 10:28 systemd-private-498ec864aba84a1386677fd745b360c5-named.service-bMuAya
drwx------ 3 root root 4096 Aug 23 10:28 systemd-private-498ec864aba84a1386677fd745b360c5-named.service-gJmHrn
drwxrwxrwt 2 root root 4096 Aug 23 10:28 .Test-unix
drwxrwxrwt 2 root root 4096 Aug 23 10:28 .X11-unix
drwxrwxrwt 2 root root 4096 Aug 23 10:28 .XIM-unix

Is there anything important for normal working of cPanel?
In backup files I do not see that files under /tmp are backuped in system files?

Best regards,
Elizabeta
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,908
2,216
463
Hello @Elizabeta,

The only essential file you should recreate is the MySQL socket symbolic link. To do so, run the following file:

Code:
ln -s /var/lib/mysql/mysql.sock /tmp/mysql.sock
The OS and/or cPanel & WHM should regenerate any other required files in /tmp as needed.

I have cPanel&WHM version 72.0.11
As a reminder, cPanel & WHM version 72 is now at end-of-life status:

Reminder: cPanel & WHM Version 72 now EOL

Thank you.
 

Elizabeta

Well-Known Member
Mar 21, 2018
248
33
28
Mostar
cPanel Access Level
Root Administrator
Hello Michael,

Thank you very much for your answer.
I did not delete everything under /tmp
I have a sym link


[[email protected] tmp]# ls -la mysql.sock
lrwxrwxrwx 1 root root 30 Ruj 17 12:20 mysql.sock -> ../../var/lib/mysql/mysql.sock

Also, I have a plan to upgrade cPanel to 74.0.6 stable version.

Best regards,
Elizabeta
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,908
2,216
463
Hello @Elizabeta,

If that symbolic link exists, then you should be all set. Let us know if you have any additional questions.

Thank you.