Language Selection

English French German Italian Portuguese Spanish

Change Prompt Color when logged in as Root

Filed under
HowTos

All security books will recommend you not to allow root SSH logins to your Linux machines. So most of us (administrators) commonly SSH with our regular user credentials and then use "su" to escalate our privileges in order to perform root tasks. If you do this frequently, sometimes it gets a little confusing to make out if you are currently root or regular user. To determine your current status you probably you end up looking at your prompt or type in "whoami".

In this article, I will show you how to change the color of your prompt when you escalate your privileges to a super-user. This technique is a good way to remind yourself that you are holding high privileges (so don’t do anything stupid). This tip is for administrator’s convenience and helps out more if you are managing large number of Linux servers.

Step 1: Login and escalate your privileges to a Super-User

I have a regular user account (username=param) on a Linux server. So in this step, I simply login to the server and then used “su” command to escalate my privileges to a Super-User.

Full Story.

More in Tux Machines

FreeBSD 10.3 Now In Beta

FreeBSD developers have released today their first official development media for the upcoming FreeBSD 10.3. FreeBSD 10.3 Beta 1 is now available from their FTP server. Read more

today's leftovers

Leftovers: Software

  • An intro to git gui
    I have been using git for years now, I think I can say I know the tool quite well, yet I do all my commits with git gui. This often surprises my coworkers because a) it looks a bit ugly and b) it's a graphical application! The horror!
  • 15 years of VLC and VideoLAN
    Technically, today is the 15th anniversary of the relicensing of all the VideoLAN software to the GPL license, as agreed by the École Centrale Paris, on February 1st, 2001.
  • LiVES Video Editor 2.6.0 Version Released For Ubuntu/Linux Mint Via PPA
    As you know there are plenty of video editors available for other operating systems (Mac, Windows) but there isn't lack of best video editors for Unix/Linux and support wide variety of architecture (x86, amd64, x86_64, i64, sparc, hppa, ppc and xbox/x86.) but using the PPA you can only install for x86/x86_64/amd64 architectures. If you are into video editing and looking for open-source and free alternative for yourself then here is great video editing program "LiVES" for you. LiVES is an awesome, very simple, powerful video editor and VJ tool exist for Linux operating system. Using LiVES video editor you can combine realtime and rendered effects, streams and multiple video/audio files, and then encode to over 50 formats. It is small in size, yet it has many advanced features. LiVES is part editor, part VJ tool. It is fully extendable through open standard RFX plugin scripts.
  • Firejail 0.9.38 Release Announcement
    We are happy to announce the release of Firejail version 0.9.38 (download). Firejail is a generic Linux namespaces security sandbox, capable of running graphic interface programs as well as server programs. The project went through an external security audit, and several SUID-releated problems have been found. Please update your software.

Kernel Space: Linux, Graphics