Disk Space And Ram Is Full On SafeSquid Server

Post your questions here, if you are not sure where you should.
Note: your post may be moved to appropriate forum by moderators.
India samidha
Posts: 74
Joined: Wed Apr 24, 2019 6:57 am
Location: Mumbai

Disk Space And Ram Is Full On SafeSquid Server

Post by samidha » Mon Jun 24, 2019 12:32 pm

Manage disk space on SafeSquid server. When any of the partitions that are used by SafeSquid are full, it results in undefined behavior.
This may lead to something like, SafeSquid failing in processing the connections.

India samidha
Posts: 74
Joined: Wed Apr 24, 2019 6:57 am
Location: Mumbai

Re: Disk Space And Ram Is Full On SafeSquid Server

Post by samidha » Mon Jun 24, 2019 12:33 pm

Give the enough size to backup store.
Example : If you want to take a backup of files of size 5GB then consider the store upto 5.5 GB
Don't delete the original log files (.log extension) and database files.
Run below command to check available disk space on each partition.
df -kh

India samidha
Posts: 74
Joined: Wed Apr 24, 2019 6:57 am
Location: Mumbai

Re: Disk Space And Ram Is Full On SafeSquid Server

Post by samidha » Mon Jun 24, 2019 12:33 pm

You will see the Used and Available size on each partition.

Code: Select all

Filesystem		                  Size   	Used  	Avail  	Use%  	Mounted on
udev                                      735M   	4.0K  	 735M  	1% 	    	/dev
tmpfs                                     150M   	428K  	 149M  	1% 	    	/run
/dev/dm-2                             4.9G	4.2G	424M	91%	/
none                                      4.0K   	0 	     4.0K  	0% 	/sys/fs/cgroup
none                                      5.0M   	0 	     5.0M  	0% 	/run/lock
none                                      746M   	0 	     746M  	0%  	/run/shm
none                                      100M   	0 	     100M  	0% 		/run/user
/dev/sda1                                 232M   	37M  	 179M  	17% 	/boot
/dev/mapper/dev--vg-var+cache+safesquid   1.8G   	2.8M  	 1.7G  	1% 		/var/cache/safesquid
/dev/mapper/dev--vg-usr+local+safesquid   1.8G   	44M  	 1.7G  	3% 		/usr/local/safesquid
/dev/mapper/dev--vg-var+db+safesquid      15G   	193M  	  14G  	2% 		/var/db/safesquid
/dev/mapper/dev--vg-var+log+safesquid     15G   	171M  	  14G   2%  	/var/log/safesquid
/dev/ram1                                 62M   	1.3M  	  58M  	3% 		/tmp/safesquid
If any of the above partitions are observed to be used over 80%, then you may take backup of the following files and delete files as per your requirement.

India samidha
Posts: 74
Joined: Wed Apr 24, 2019 6:57 am
Location: Mumbai

Re: Disk Space And Ram Is Full On SafeSquid Server

Post by samidha » Mon Jun 24, 2019 12:34 pm

/var/log

You can also take the backup of system logs and delete the files with .gz extension. This folder contains the logs related to system, so don't delete or modify the original files (i.e. with .log extension).

Example : dmesg.1.gz
Top

India samidha
Posts: 74
Joined: Wed Apr 24, 2019 6:57 am
Location: Mumbai

Re: Disk Space And Ram Is Full On SafeSquid Server

Post by samidha » Mon Jun 24, 2019 12:34 pm

/var/cache/safesquid

Delete all files from this folder by using below command. No need to take a backup of any file from this folder

rm -rf *

India samidha
Posts: 74
Joined: Wed Apr 24, 2019 6:57 am
Location: Mumbai

Re: Disk Space And Ram Is Full On SafeSquid Server

Post by samidha » Mon Jun 24, 2019 12:34 pm

/var/db/safesquid

Delete all files except these three files from the directory : /var/db/safesquid/report/

safesquid2.db
safesquid2.db-wal
safesquid2.db-shm

These files will be used to store the data required for reports generation

you can take a back up or directly delete these files.

Note : If you delete or moved the above files to other destination then restart the SafeSquid server, in order to create the deleted or moved files.

India samidha
Posts: 74
Joined: Wed Apr 24, 2019 6:57 am
Location: Mumbai

Re: Disk Space And Ram Is Full On SafeSquid Server

Post by samidha » Mon Jun 24, 2019 12:34 pm

/var/log/safesquid

Change the directory to :/var/log/safesquid/native/ by using below command

cd /var/log/safesquid/native/

Native logs used to store the data related to requests and responses. You can delete all files in this folder, No back up is required.
Example file name to be deleted : 20161223132118-safesquid.log.gz

Change the directory to : /var/log/safesquid/extended/ by using below command

cd /var/log/safesquid/extended/

Extended logs used to store the data related to users information for each connection. Take a backup of these files if required.
Example file name to be deleted : 20161223132118-extended.log.gz

Change the directory to : /var/log/safesquid/performance/ by using below command

cd /var/log/safesquid/performance/

Performance logs used to store the data related to safesquid performance statistics. You can take a backup if required and delete.
Example file name to be deleted : 20161223132118-performance.log.gz

Change the directory to :/var/log/safesquid/config/ by using below command

cd /var/log/safesquid/config/

config logs used to store the data related to safesquid interface requests and responses. No need to take a back up of these files.
Example file name to be deleted : 20161223132118-config.log.gz

India samidha
Posts: 74
Joined: Wed Apr 24, 2019 6:57 am
Location: Mumbai

Re: Disk Space And Ram Is Full On SafeSquid Server

Post by samidha » Mon Jun 24, 2019 12:35 pm

/tmp/safesquid

Delete all files and folders present in this directory. By using this command

rm -rf *

This memory will be used only in upgradation time


Please login to post comments.

Post Reply