linux-execute-a-binary-in-background

[Linux] How to Excute Binary in Background

1. Problem You may meet the situation where you want to execute a binary in Linux, but you don’t want to keep the terminal open. You want to close the terminal and let the binary run in the background. 2. Solution In Linux, you can use the nohup command to run a binary in the background. The nohup command is used to run a command or script that keeps running after you log out of a shell. ...

[Linux] How to Compress Folder and Decompress File

1. Compress a folder To compress a folder in Linux, you can use the tar command. The tar command is used to create, manage, and extract files that are archived in the tar format. To compress a folder, you can use the -czvf flags, which tell tar to create a compressed archive, use gzip compression, be verbose, and use the file name that follows. First, navigate to the directory containing the folder you want to compress. Then, run the following command: ...

[Linux] How to Download Files and Folders from Remote Server

To use scp to download a file from a remote server to your local machine, you can use the following syntax: scp username@host:/path/to/remote/file /path/to/local/destination This will download the file located at /path/to/remote/file on the remote server, and save it to /path/to/local/destination on your local machine. You will need to replace username with your username on the remote server, host with the hostname or IP address of the remote server, and /path/to/remote/file and /path/to/local/destination with the actual paths to the remote file and the local destination, respectively. ...

Linux Handbook (🚧Continuous Update)

1. Set up permanent alias alais boltbrowser="bb" source .bashrc 2. Mount the external drive permanently See other posts: How to mount the external hard drive permanently External hard drive is read-only 3. Check which process owns the specific port sudo netstat -tulpn sudo netstat -tulpn | grep 80 # or sudo ss -tulpn sudo ss -tulpn | grep 80 # or sudo ps aux sudo ps aux | grep 80 4. Open an url in web browser from Terminal xdg-open https://google.com 5. Delete the installed package with apt # Check the apt installed history gtrep " install " /var/log/apt/history.log # Only remove the package but keep the configuration sudo apt remove <package_name> # Remove both package and configuration sudo apt purge <package_name> 6. List all the block devices lsblk -f Output is like ...

[GIMP/Linux] How to highlight on the screenshot with GIMP on Linux

Since I changed my Operating System from Windows to Ubuntu, I have been looking for a tool that can make a screenshot and put a highlight on it. Something like the Snipping Tool on Windows. It is hard to find such tool on Linux. However, I found a way to achieve the goal with two tools. Screenshot (Ubuntu installed software. Open it from Ubuntu Activities) GIMP (GNU Image Manipulation Program. Download from https://www.gimp.org/downloads/) This post will show how to use the above tool to highlight a screenshot step by step. ...

[Linux] Error: ENOSPC: System limit ...

I can do general frontend work, but I’m not specialized in front end. Today when I run up the front-end project, I met the following issue. Error: Watchpack Error (watcher): Error: ENOSPC: System limit for number of file watchers reached... The reason is that there is restriction of opening files by one process in Linux. The default number of opening file might be too limited especially when you run with webpack. The solution is to increase the limitation. You can change as below. ...

DigitalOcean Referral Badge
Sign up to get $200, 60-day account credit !