Ignore a folder in maldet

maldet is malware scanner for linux. On a shared hosting server, maldet detected one cusomer files as malware, on checking i found it is false positive. It is just a log file written by the application. To avoid getting further email from this application, i added this folder to maldet ignore_paths.

To add a folder to ignore list, edit file

Add the folder you need to ignore to end of this file as a new line.

Example

See maldet

Enable Passive FTP in ISPConfig

To enable Passive FTP in Debian/Ubuntu installation of ISPConfig, run

Restart pure-ftpd

Now open ports 40110-40210 in firewall.

On CSF Firewall, edit

Add

At ened of TCP_IN line.

Example

See ispconfig

Reorder windows in tmux

To reorder windows in tmux, you can use following command

Press CTRL + B or whatever prefix you use, then press . (dot). This will ask you number/position where you need current window moved.

Another method is

This will give you tmux command promt. Now enter

This will move current window to position 0. This only work if position 0 is empty. If another window already present in position 0, use swap-window command.

This with swap current window with window in position 0.

Another useful command is

This will allow you to rename current tmux window.

Using shortcuts

You can edit .tmux.conf file and add following

Now you can use CTRL + SHIFT + LEFT OR RIGHT arrow to move windows.

See tmux

vmstat

vmstat 1

* High values in “wa” column mean: IO problem
* High values in “si”, “so” mean: excessive swapping

Sustained high swap rates (si and so) are usually bad. The system will start spending all of its time swapping, and make no progress on any actual work. You will also see the number of runnable (r and b) processes increase. If the situation gets bad enough and free memory gets too low, the Out-of-memory (oom) logic will start killing random processes. At this point, either reducing the number of processes that normally run or adding additional RAM are about the only options.

vmstat – Report virtual memory statistics

vmstat reports information about processes, memory, paging, block IO, traps, and cpu activity.

The first report produced gives averages since the last reboot. Additional reports give information on a sampling period of length delay. The process and memory reports are instantaneous in either case.

FIELD DESCRIPTION FOR VM MODE

FIELD DESCRIPTION FOR DISK MODE

FIELD DESCRIPTION FOR DISK PARTITION MODE

FIELD DESCRIPTION FOR SLAB MODE

Related commands

* iostat
* sar
* mpstat
* ps
* top
* free

See Linux Commands

Disable Netdata Email Notification

To disable email notifcation from netdata, run

Find

Replace with

By default, it open using nano, if you want to use vim to edit, select vim as default editor with

See netdata

find files by size

On a server, i wanted to find all log files that are larger than 1 GB in size, to do this, run

Example

To find files older than 100 days, run

See find