Linux terminal || Linux Terminal Commands


1) As an example, if we tend to entered "apt install htop" while not sudo, a slip is came back indicating that "sudo" is needed.

  • > apt install htop
  • > sudo !!
  •  

2) use caution if your last command was "poweroff" whereas you kind !! and press Enter, you guessed it, the system can closing.

Not sure what the last team was? use the "history" command to ascertain the last command and even additional back Team add the background

To keep the command running within the background, use "Ctrl + Z", use "fg" to bring it back (fg: foreground)


eg:

> nano /etc/apt/sources.list

> Ctrl + Z

# (Execute the other needed commands)


# currently we're back to nano

 > Cancel closing


# If clicked closing from interface use following command to undo

shutdown -c


 # If the closing procedure has started, use the subsequent command to cancel

> pkill closing

 

3) Execute a command at a particular time

We may have to put in the "at" command 1st


# Debian / Ubuntu / Kali UNIX operating system, etc.

> sudo apt install at

 

# RHEL / CentOS / lid, etc.

> sudo dnf install at 01:20 Tue

 > poweroff

 > Ctrl + D

Post a Comment

Please do not enter any spam link in the comment box.

Previous Post Next Post