/var/log keeps accumulating in jetson, which eventually leads to full storage capacity

Hello,

/var/log keeps accumulating in jetson, which eventually leads to full storage capacity.
What are some ways to solve this?
Since it is an edge device, it is difficult to put a separate storage device. Can you tell me how to periodically delete or backup it?

######### /var/log #################
manager@manager-desktop:/var/log$ ll -h
total 176M
drwxrwxr-x 5 root syslog 4.0K 10월 1 00:09 ./
drwxr-xr-x 15 root root 4.0K 5월 26 19:22 …/
-rw-r–r-- 1 root root 0 10월 1 00:09 alternatives.log
-rw-r–r-- 1 root root 3.9K 9월 15 11:31 alternatives.log.1
-rw-r----- 1 root adm 0 9월 28 00:09 apport.log
-rw-r----- 1 root adm 5.2K 9월 27 17:55 apport.log.1
-rw-r----- 1 root adm 370 9월 15 11:12 apport.log.2.gz
drwxr-xr-x 2 root root 4.0K 10월 1 00:09 apt/
-rw-r----- 1 syslog adm 90K 10월 1 09:19 auth.log
-rw-r----- 1 syslog adm 66K 9월 25 23:17 auth.log.1
-rw-r----- 1 syslog adm 5.8K 9월 18 23:17 auth.log.2.gz
-rw-rw---- 1 root utmp 0 10월 1 00:09 btmp
-rw-rw---- 1 root utmp 2.8K 9월 30 17:39 btmp.1
-rw-r–r-- 1 root root 0 10월 1 00:09 dpkg.log
-rw-r–r-- 1 root root 133K 9월 15 11:32 dpkg.log.1
drwx–x–x 2 root gdm 4.0K 9월 15 10:14 gdm3/
drwxr-xr-x 2 root root 4.0K 9월 15 10:11 installer/
-rw-r----- 1 syslog adm 379K 9월 30 20:33 kern.log
-rw-r----- 1 syslog adm 364K 9월 24 13:36 kern.log.1
-rw-r----- 1 syslog adm 112K 9월 18 08:30 kern.log.2.gz
-rw-rw-r-- 1 root utmp 290K 10월 1 09:19 lastlog
-rw-rw-rw- 1 root root 319 9월 30 15:25 nic_diskerr.log
-rw-r–r-- 1 root root 1.8K 9월 15 10:12 oem-config.log
-rw-r–r-- 1 root root 447 9월 30 17:42 storage00.info
-rw-r–r-- 1 root root 304 9월 30 17:41 storage01.info
-rw-r–r-- 1 root root 304 9월 30 17:41 storage02.info
-rw-r–r-- 1 root root 304 9월 30 17:41 storage03.info
-rw-r–r-- 1 root root 354 9월 30 15:27 storage.info.log
-rw-r----- 1 syslog adm 40M 10월 1 09:19 syslog
-rw-r----- 1 syslog adm 134M 10월 1 00:09 syslog.1
-rw------- 1 root root 63K 9월 15 10:13 tallylog
-rw-rw-r-- 1 root utmp 400 10월 1 09:19 wtmp
-rw-rw-r-- 1 root utmp 58K 9월 30 17:42 wtmp.1
-rw-r–r-- 1 root root 11K 9월 30 17:42 Xorg.0.log
-rw-r–r-- 1 root root 12K 9월 30 17:40 Xorg.0.log.old
-rw-r–r-- 1 root root 14K 9월 24 11:03 Xorg.1.log
-rw-r–r-- 1 root root 24K 9월 15 14:20 Xorg.1.log.old

Thank you.

You can refer to this.

1 Like