How To: Use the "Open as Root" Context Menu in Nemo
Forum rules
Please don't add support questions to tutorials,start your own thread in the appropriate sub-forum instead. Before you post please read this
Please don't add support questions to tutorials,start your own thread in the appropriate sub-forum instead. Before you post please read this
How To: Use the "Open as Root" Context Menu in Nemo
I am new to Linux having come from a Windows environment.
I am using Linux Mint Cinnamon 19.2 and really think it is great, once you learn about some of its niftier features.
Today, I wanted to backup (copy) some files which were generated by an application which I run as root using sudo.
I found that Nemo out-of-the-box would not let me access the files directly since they were owned by root, even though I have root privileges. And it is not recommended to run Nemo with sudo. It generates errors and this warned me off.
But here is one way to do it using a built-in feature of Nemo, a very handy context menu for "Open as Root".
Find the folder which you want to copy but is owned by root. Highlight its parent folder in the left hand tree view of the Nemo File Manager. The folder will now appear as an icon in the right hand directory view. (In the image below, the parent folder is Photos which in not shown in the tree view in this image.) Right click on the desired folder icon to display the context menu. One of the options is "Open as Root" with a little key icon. Select this and enter the root password as required. A new Nemo window will open with a warning banner colored red saying Elevated Privileges. Use this new Nemo window to copy as usual and paste to the destination directory. When the copy completes, close the elevated privileges window so you do not inadvertently do something unintended as root in the file system.
One other handy little feature of Nemo is the ability to show "hidden" files, that is files which start with a . as in .bashrc. You can do this by toggling Ctrl-h while looking at the directory of interest, or in the View Menu by checking the option to Show Hidden Files.
I am using Linux Mint Cinnamon 19.2 and really think it is great, once you learn about some of its niftier features.
Today, I wanted to backup (copy) some files which were generated by an application which I run as root using sudo.
I found that Nemo out-of-the-box would not let me access the files directly since they were owned by root, even though I have root privileges. And it is not recommended to run Nemo with sudo. It generates errors and this warned me off.
But here is one way to do it using a built-in feature of Nemo, a very handy context menu for "Open as Root".
Find the folder which you want to copy but is owned by root. Highlight its parent folder in the left hand tree view of the Nemo File Manager. The folder will now appear as an icon in the right hand directory view. (In the image below, the parent folder is Photos which in not shown in the tree view in this image.) Right click on the desired folder icon to display the context menu. One of the options is "Open as Root" with a little key icon. Select this and enter the root password as required. A new Nemo window will open with a warning banner colored red saying Elevated Privileges. Use this new Nemo window to copy as usual and paste to the destination directory. When the copy completes, close the elevated privileges window so you do not inadvertently do something unintended as root in the file system.
One other handy little feature of Nemo is the ability to show "hidden" files, that is files which start with a . as in .bashrc. You can do this by toggling Ctrl-h while looking at the directory of interest, or in the View Menu by checking the option to Show Hidden Files.
Last edited by Daisuke on Thu Nov 14, 2019 5:08 pm, edited 2 times in total.
Re: How To: Use the "Open as Root" Context Menu in Nautilus
Nice tutorial, but one little niggle - Cinnamon's File Manager is called Nemo not Nautilus. The latter is the the Gnome 3 desktop environments file manager.
For custom Nemo actions, useful scripts for the Cinnamon desktop, and Cinnamox themes visit my Github pages.
Re: How To: Use the "Open as Root" Context Menu in Nautilus
This .. and it's really not a good idea to install a second full-blown file manager as this can (and apparently has) lead to serious borkage of your operating system.

Dell Inspiron 1525 - LM17.3 CE 64-------------------Lenovo T440 8GB - Manjaro KDE with Mint VMs
Toshiba NB250 - Manjaro KDE------------------------K7S5A AMD 1.2GHz - LM17.3 Xfce 32 & WinXP-Pro
Acer Aspire E11 ES1-111M - LM18.2 KDE 64 ----Dell PII 350 64MB - Puppy 4.3 & Win98-SE
Toshiba NB250 - Manjaro KDE------------------------K7S5A AMD 1.2GHz - LM17.3 Xfce 32 & WinXP-Pro
Acer Aspire E11 ES1-111M - LM18.2 KDE 64 ----Dell PII 350 64MB - Puppy 4.3 & Win98-SE
Re: How To: Use the "Open as Root" Context Menu in Nautilus
To Smurfos,
Thanks for the encouragement! Also, for clearing up my confusion over the use of Nautilus and Nemo. As my image shows, I am using Nemo!
To BG405,
Thanks for the comment. My error was in calling the Mint-Cinnamon File Manager Nautilus, not its correct name of Nemo. A rose by any other name may smell as sweet, but a File Manager should always be named properly!
I have edited the tutorial to show the correct file manager application (Nemo) for this tutorial but which I was calling by a different name.
As an interesting piece of trivia, both Nautilus and Nemo come from the famous novels by Jules Verne, Twenty Thousand Leagues Under the Sea (1870) and The Mysterious Island (1874). Nautilus is the fictional submarine which was captained by Nemo in the novels. In thinking about the file system as the below the surface region on which Linux, or any OS, is built, both Nemo and Nautilus, as underwater explorers, make for a good metaphor!
Thanks for the encouragement! Also, for clearing up my confusion over the use of Nautilus and Nemo. As my image shows, I am using Nemo!
To BG405,
Thanks for the comment. My error was in calling the Mint-Cinnamon File Manager Nautilus, not its correct name of Nemo. A rose by any other name may smell as sweet, but a File Manager should always be named properly!
I have edited the tutorial to show the correct file manager application (Nemo) for this tutorial but which I was calling by a different name.
As an interesting piece of trivia, both Nautilus and Nemo come from the famous novels by Jules Verne, Twenty Thousand Leagues Under the Sea (1870) and The Mysterious Island (1874). Nautilus is the fictional submarine which was captained by Nemo in the novels. In thinking about the file system as the below the surface region on which Linux, or any OS, is built, both Nemo and Nautilus, as underwater explorers, make for a good metaphor!
- absque fenestris
- Level 6
- Posts: 1284
- Joined: Sat Nov 12, 2016 8:42 pm
- Location: Confoederatio Helvetica
Re: How To: Use the "Open as Root" Context Menu in Nautilus
So to speak I "grew up" with Gnome 2 and Ubuntu & Debian and for me the file browser is still "Nautilus"
At least I change the icon to the Nautilus shell...
At least I change the icon to the Nautilus shell...
Linux Mint 18.3 Sylvia (Mate) 32-bit - Acer D250 Netbook (Intel Atom N270, 2 GB RAM, 120 GB SSD)
Linux Mint 17.3 Rosa (Mate) 64-bit - MacBook Pro 15" (Intel Core2 Duo, 8 GB RAM, 240 GB SSD) - with some separation difficulties...
Linux Mint 17.3 Rosa (Mate) 64-bit - MacBook Pro 15" (Intel Core2 Duo, 8 GB RAM, 240 GB SSD) - with some separation difficulties...
Re: How To: Use the "Open as Root" Context Menu in Nautilus
Yes, indeed! That might well have been the idea behind these names & also in KDE we have Dolphin as the file manager, also marine related.
By the way, it would be a good idea to change the title of your opening post accordingly.

Dell Inspiron 1525 - LM17.3 CE 64-------------------Lenovo T440 8GB - Manjaro KDE with Mint VMs
Toshiba NB250 - Manjaro KDE------------------------K7S5A AMD 1.2GHz - LM17.3 Xfce 32 & WinXP-Pro
Acer Aspire E11 ES1-111M - LM18.2 KDE 64 ----Dell PII 350 64MB - Puppy 4.3 & Win98-SE
Toshiba NB250 - Manjaro KDE------------------------K7S5A AMD 1.2GHz - LM17.3 Xfce 32 & WinXP-Pro
Acer Aspire E11 ES1-111M - LM18.2 KDE 64 ----Dell PII 350 64MB - Puppy 4.3 & Win98-SE
Re: How To: Use the "Open as Root" Context Menu in Nemo
Thank you BG405! Great catch - you are observant and kind enough to remind me in a friendly way! Done!
Re: How To: Use the "Open as Root" Context Menu in Nemo
@Daisuke: No worries, thanks. This sort of thing is easily missed/overlooked etc. & I've with little or no doubt done it myself on numerous occasions. It's great that you are contributing good stuff to our great community and it's really appreciated.
.. as an aside I don't get it why some people seemingly want to do nothing other than complain .. there are Forums for that too! (Not necessarly Linux ones, but it happens). 


Dell Inspiron 1525 - LM17.3 CE 64-------------------Lenovo T440 8GB - Manjaro KDE with Mint VMs
Toshiba NB250 - Manjaro KDE------------------------K7S5A AMD 1.2GHz - LM17.3 Xfce 32 & WinXP-Pro
Acer Aspire E11 ES1-111M - LM18.2 KDE 64 ----Dell PII 350 64MB - Puppy 4.3 & Win98-SE
Toshiba NB250 - Manjaro KDE------------------------K7S5A AMD 1.2GHz - LM17.3 Xfce 32 & WinXP-Pro
Acer Aspire E11 ES1-111M - LM18.2 KDE 64 ----Dell PII 350 64MB - Puppy 4.3 & Win98-SE