How to run Dolphin as root?
I currently use dolphin 17.04.3
and whenever I run it as sudo, it gives the following error
Executing Dolphin as root is not possible.
without explaining why or giving an alternative. So how can I run dolphin as root for copying or deleting files?
kde root dolphin
|
show 1 more comment
I currently use dolphin 17.04.3
and whenever I run it as sudo, it gives the following error
Executing Dolphin as root is not possible.
without explaining why or giving an alternative. So how can I run dolphin as root for copying or deleting files?
kde root dolphin
What version of Ubuntu are you using?
– George Udosen
Dec 29 '17 at 17:38
1
are you using wayland? by default wayland does not allow GUI programs to run as root.
– ravery
Dec 29 '17 at 17:42
doesn't work. the option to create or move files is simply greyed out in the context menu. Please check your version
– Ankur S
Dec 29 '17 at 17:51
I'm using ubuntu 17.10 and x11 with kde installed
– Ankur S
Dec 29 '17 at 17:56
2
"So how can I run dolphin as root for copying or deleting files?" Please re-evaluate this question. Use command line for admin tasks. It is there specifically for admin tasks. Graphical tools should not be used for admin tasks. Running graphical tools as admin has unseen side effects regarding permissions and as of late is deemed such that the developers actively block it. Do you really think it is a good idea to go against the people that know (or are supposed to know ;) ) exactly what a graphical files manipulation tool can and does?
– Rinzwind
Dec 29 '17 at 20:23
|
show 1 more comment
I currently use dolphin 17.04.3
and whenever I run it as sudo, it gives the following error
Executing Dolphin as root is not possible.
without explaining why or giving an alternative. So how can I run dolphin as root for copying or deleting files?
kde root dolphin
I currently use dolphin 17.04.3
and whenever I run it as sudo, it gives the following error
Executing Dolphin as root is not possible.
without explaining why or giving an alternative. So how can I run dolphin as root for copying or deleting files?
kde root dolphin
kde root dolphin
asked Dec 29 '17 at 17:33
Ankur SAnkur S
2621314
2621314
What version of Ubuntu are you using?
– George Udosen
Dec 29 '17 at 17:38
1
are you using wayland? by default wayland does not allow GUI programs to run as root.
– ravery
Dec 29 '17 at 17:42
doesn't work. the option to create or move files is simply greyed out in the context menu. Please check your version
– Ankur S
Dec 29 '17 at 17:51
I'm using ubuntu 17.10 and x11 with kde installed
– Ankur S
Dec 29 '17 at 17:56
2
"So how can I run dolphin as root for copying or deleting files?" Please re-evaluate this question. Use command line for admin tasks. It is there specifically for admin tasks. Graphical tools should not be used for admin tasks. Running graphical tools as admin has unseen side effects regarding permissions and as of late is deemed such that the developers actively block it. Do you really think it is a good idea to go against the people that know (or are supposed to know ;) ) exactly what a graphical files manipulation tool can and does?
– Rinzwind
Dec 29 '17 at 20:23
|
show 1 more comment
What version of Ubuntu are you using?
– George Udosen
Dec 29 '17 at 17:38
1
are you using wayland? by default wayland does not allow GUI programs to run as root.
– ravery
Dec 29 '17 at 17:42
doesn't work. the option to create or move files is simply greyed out in the context menu. Please check your version
– Ankur S
Dec 29 '17 at 17:51
I'm using ubuntu 17.10 and x11 with kde installed
– Ankur S
Dec 29 '17 at 17:56
2
"So how can I run dolphin as root for copying or deleting files?" Please re-evaluate this question. Use command line for admin tasks. It is there specifically for admin tasks. Graphical tools should not be used for admin tasks. Running graphical tools as admin has unseen side effects regarding permissions and as of late is deemed such that the developers actively block it. Do you really think it is a good idea to go against the people that know (or are supposed to know ;) ) exactly what a graphical files manipulation tool can and does?
– Rinzwind
Dec 29 '17 at 20:23
What version of Ubuntu are you using?
– George Udosen
Dec 29 '17 at 17:38
What version of Ubuntu are you using?
– George Udosen
Dec 29 '17 at 17:38
1
1
are you using wayland? by default wayland does not allow GUI programs to run as root.
– ravery
Dec 29 '17 at 17:42
are you using wayland? by default wayland does not allow GUI programs to run as root.
– ravery
Dec 29 '17 at 17:42
doesn't work. the option to create or move files is simply greyed out in the context menu. Please check your version
– Ankur S
Dec 29 '17 at 17:51
doesn't work. the option to create or move files is simply greyed out in the context menu. Please check your version
– Ankur S
Dec 29 '17 at 17:51
I'm using ubuntu 17.10 and x11 with kde installed
– Ankur S
Dec 29 '17 at 17:56
I'm using ubuntu 17.10 and x11 with kde installed
– Ankur S
Dec 29 '17 at 17:56
2
2
"So how can I run dolphin as root for copying or deleting files?" Please re-evaluate this question. Use command line for admin tasks. It is there specifically for admin tasks. Graphical tools should not be used for admin tasks. Running graphical tools as admin has unseen side effects regarding permissions and as of late is deemed such that the developers actively block it. Do you really think it is a good idea to go against the people that know (or are supposed to know ;) ) exactly what a graphical files manipulation tool can and does?
– Rinzwind
Dec 29 '17 at 20:23
"So how can I run dolphin as root for copying or deleting files?" Please re-evaluate this question. Use command line for admin tasks. It is there specifically for admin tasks. Graphical tools should not be used for admin tasks. Running graphical tools as admin has unseen side effects regarding permissions and as of late is deemed such that the developers actively block it. Do you really think it is a good idea to go against the people that know (or are supposed to know ;) ) exactly what a graphical files manipulation tool can and does?
– Rinzwind
Dec 29 '17 at 20:23
|
show 1 more comment
3 Answers
3
active
oldest
votes
Short:
Dolphin 17.04
The Dolphin 17.04 or later has a check:
if uid == 0 then show the "Executing Dolphin as root is not possible." and exit.
A workaround
You could edit the sources and disable the check. Then the Dolphin will work as before.
Dolphin 18.08
Few review request
Re-allow running Dolphin as the root user (but still not using sudo): https://phabricator.kde.org/D12795
Show a warning when running as the root user: https://phabricator.kde.org/D12732
Dolphin 18.08.0 is using these changes and the Dolphin can be launched with the pkexec command as the administrative super user.
pkexec env DISPLAY=$DISPLAY XAUTHORITY=$XAUTHORITY KDE_SESSION_VERSION=5 KDE_FULL_SESSION=true dolphin
More: KDE Foruns - How to run Dolphin 18.08 as root with Kubuntu or KDE neon? - https://forum.kde.org/viewtopic.php?f=224&t=153655
Background:
Earlier - KDE Forums - How to run Dolphin as root?: https://forum.kde.org/viewtopic.php?f=224&t=141836
For the security reasons: Disallow executing Dolphin as root on Linux - https://cgit.kde.org/dolphin.git/commit/?id=0bdd8e0b0516555c6233fdc7901e9b417cf89
Disallow executing Dolphin as root on Linux Basically a copy of commit
kate/9adcebd3c2e476c8a32e9b455cc99f46b0e12a7e which was written by
Martin Grässlin
Disallow executing kate and kwrite as root on Linux: https://phabricator.kde.org/R40:9adcebd3c2e476c8a32e9b455cc99f46b0e12a7e
More tips
KDE Reddit - Dolphin root on KDE App 17.04 : https://www.reddit.com/r/kde/comments/6785b1/dolphin_root_on_kde_app_1704/
Bypass "Executing Dolphin as root is not possible" and Regain KDE Dolphin Root Privileges: https://www.reddit.com/r/kde/comments/6xs3mp/bypass_executing_dolphin_as_root_is_not_possible/
Future
Polkit support in KIO: https://phabricator.kde.org/T6561
When it is ready the Dolphin will show the password query if needed. Now, with the patched Dolphin&KIO:
Could you elaborate a little bit more on the "For the security reasons"?
– Jim McAdams
Feb 26 '18 at 21:21
Did you read the phabricator.kde.org/… . Same / more : Martin Grässlin - Editing files as root: blog.martin-graesslin.com/blog/2017/02/editing-files-as-root
– user26687
Mar 5 '18 at 9:47
so, the simple answer is "you cannot run Dolphin as root, unless you install a patched version"?
– user47206
Jun 22 '18 at 9:56
add a comment |
Not an answer, just a workaround for the purpose mentioned by the OP (copying or deleting files
).
The idea is to
install another file manger that doesn't have that limitation and that doesn't bring a lot of dependencies
create an "Open as root" context menu in Dolphin for this other file manager.
The main file managers of other desktops can be used (Nautilus, Nemo, Caja, Thunar) but they do bring some dependencies. Even PCManFM and PCManFM-Qt do that. If you need one of those for some other purpose adding that one could be a good solution.
I have found that Krusader (which I think in the past used to be installed by default in some KDE systems) can be easily installed, brings no dependencies in Kubuntu 18.04, and can be used as root.
sudo apt install krusader
Under its Tools it has the "Root" option.
which asks for password in a gui.
To add a context menu in dolphin, create the folder ~/.local/share/kservices5/ServiceMenus
and then do
kate ~/.local/share/kservices5/ServiceMenus/filemanager_root.desktop
and add
[Desktop Action root]
Exec=/usr/lib/kde4/libexec/kdesu krusader
Icon=dolphin
Name=Open in Krusader file manger as administrator
[Desktop Entry]
Actions=root
Icon=krusader_root
MimeType=inode/directory
ServiceTypes=KonqPopupMenu/Plugin
Type=Service
X-KDE-Priority=TopLevel
X-KDE-StartupNotify=false
For some reason kdesu krusader
doesn't work, and I have used the solution from here.. What also works is konsole -e sudo krusader
, but that shows the terminal instead of a gui for the password prompt.
Then, you'll see in Dolphin:
bringing a dialog
which is one that works..
add a comment |
I have made my own version based on the replies above.
So, to add a context menu to open Dolphin as root follow these steps:
- Create a file called for example
DolphinAsRoot.desktop
on the directory~/.local/share/kservices5/ServiceMenus/
- With a text editor put the following content on it:
[Desktop Entry]
Actions=root
Icon=system-file-manager-root
MimeType=inode/directory
ServiceTypes=KonqPopupMenu/Plugin
Type=Service
X-KDE-Priority=TopLevel
X-KDE-StartupNotify=false
[Desktop Action root]
Exec=/usr/bin/pkexec env DISPLAY=$DISPLAY XAUTHORITY=$XAUTHORITY KDE_SESSION_VERSION=5 KDE_FULL_SESSION=true dolphin
Icon=system-file-manager-root
Name=Open as administrator
- If it still not appears on the context menu in Dolphin go to "Settings -> Configure Dolphin...-> Services" and activate the option you recently added. It should be there. If not, close Dolphin or even log out and in on your session.
That's all, I hope it helps you all like it helped me ;)
add a comment |
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "89"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f990611%2fhow-to-run-dolphin-as-root%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
3 Answers
3
active
oldest
votes
3 Answers
3
active
oldest
votes
active
oldest
votes
active
oldest
votes
Short:
Dolphin 17.04
The Dolphin 17.04 or later has a check:
if uid == 0 then show the "Executing Dolphin as root is not possible." and exit.
A workaround
You could edit the sources and disable the check. Then the Dolphin will work as before.
Dolphin 18.08
Few review request
Re-allow running Dolphin as the root user (but still not using sudo): https://phabricator.kde.org/D12795
Show a warning when running as the root user: https://phabricator.kde.org/D12732
Dolphin 18.08.0 is using these changes and the Dolphin can be launched with the pkexec command as the administrative super user.
pkexec env DISPLAY=$DISPLAY XAUTHORITY=$XAUTHORITY KDE_SESSION_VERSION=5 KDE_FULL_SESSION=true dolphin
More: KDE Foruns - How to run Dolphin 18.08 as root with Kubuntu or KDE neon? - https://forum.kde.org/viewtopic.php?f=224&t=153655
Background:
Earlier - KDE Forums - How to run Dolphin as root?: https://forum.kde.org/viewtopic.php?f=224&t=141836
For the security reasons: Disallow executing Dolphin as root on Linux - https://cgit.kde.org/dolphin.git/commit/?id=0bdd8e0b0516555c6233fdc7901e9b417cf89
Disallow executing Dolphin as root on Linux Basically a copy of commit
kate/9adcebd3c2e476c8a32e9b455cc99f46b0e12a7e which was written by
Martin Grässlin
Disallow executing kate and kwrite as root on Linux: https://phabricator.kde.org/R40:9adcebd3c2e476c8a32e9b455cc99f46b0e12a7e
More tips
KDE Reddit - Dolphin root on KDE App 17.04 : https://www.reddit.com/r/kde/comments/6785b1/dolphin_root_on_kde_app_1704/
Bypass "Executing Dolphin as root is not possible" and Regain KDE Dolphin Root Privileges: https://www.reddit.com/r/kde/comments/6xs3mp/bypass_executing_dolphin_as_root_is_not_possible/
Future
Polkit support in KIO: https://phabricator.kde.org/T6561
When it is ready the Dolphin will show the password query if needed. Now, with the patched Dolphin&KIO:
Could you elaborate a little bit more on the "For the security reasons"?
– Jim McAdams
Feb 26 '18 at 21:21
Did you read the phabricator.kde.org/… . Same / more : Martin Grässlin - Editing files as root: blog.martin-graesslin.com/blog/2017/02/editing-files-as-root
– user26687
Mar 5 '18 at 9:47
so, the simple answer is "you cannot run Dolphin as root, unless you install a patched version"?
– user47206
Jun 22 '18 at 9:56
add a comment |
Short:
Dolphin 17.04
The Dolphin 17.04 or later has a check:
if uid == 0 then show the "Executing Dolphin as root is not possible." and exit.
A workaround
You could edit the sources and disable the check. Then the Dolphin will work as before.
Dolphin 18.08
Few review request
Re-allow running Dolphin as the root user (but still not using sudo): https://phabricator.kde.org/D12795
Show a warning when running as the root user: https://phabricator.kde.org/D12732
Dolphin 18.08.0 is using these changes and the Dolphin can be launched with the pkexec command as the administrative super user.
pkexec env DISPLAY=$DISPLAY XAUTHORITY=$XAUTHORITY KDE_SESSION_VERSION=5 KDE_FULL_SESSION=true dolphin
More: KDE Foruns - How to run Dolphin 18.08 as root with Kubuntu or KDE neon? - https://forum.kde.org/viewtopic.php?f=224&t=153655
Background:
Earlier - KDE Forums - How to run Dolphin as root?: https://forum.kde.org/viewtopic.php?f=224&t=141836
For the security reasons: Disallow executing Dolphin as root on Linux - https://cgit.kde.org/dolphin.git/commit/?id=0bdd8e0b0516555c6233fdc7901e9b417cf89
Disallow executing Dolphin as root on Linux Basically a copy of commit
kate/9adcebd3c2e476c8a32e9b455cc99f46b0e12a7e which was written by
Martin Grässlin
Disallow executing kate and kwrite as root on Linux: https://phabricator.kde.org/R40:9adcebd3c2e476c8a32e9b455cc99f46b0e12a7e
More tips
KDE Reddit - Dolphin root on KDE App 17.04 : https://www.reddit.com/r/kde/comments/6785b1/dolphin_root_on_kde_app_1704/
Bypass "Executing Dolphin as root is not possible" and Regain KDE Dolphin Root Privileges: https://www.reddit.com/r/kde/comments/6xs3mp/bypass_executing_dolphin_as_root_is_not_possible/
Future
Polkit support in KIO: https://phabricator.kde.org/T6561
When it is ready the Dolphin will show the password query if needed. Now, with the patched Dolphin&KIO:
Could you elaborate a little bit more on the "For the security reasons"?
– Jim McAdams
Feb 26 '18 at 21:21
Did you read the phabricator.kde.org/… . Same / more : Martin Grässlin - Editing files as root: blog.martin-graesslin.com/blog/2017/02/editing-files-as-root
– user26687
Mar 5 '18 at 9:47
so, the simple answer is "you cannot run Dolphin as root, unless you install a patched version"?
– user47206
Jun 22 '18 at 9:56
add a comment |
Short:
Dolphin 17.04
The Dolphin 17.04 or later has a check:
if uid == 0 then show the "Executing Dolphin as root is not possible." and exit.
A workaround
You could edit the sources and disable the check. Then the Dolphin will work as before.
Dolphin 18.08
Few review request
Re-allow running Dolphin as the root user (but still not using sudo): https://phabricator.kde.org/D12795
Show a warning when running as the root user: https://phabricator.kde.org/D12732
Dolphin 18.08.0 is using these changes and the Dolphin can be launched with the pkexec command as the administrative super user.
pkexec env DISPLAY=$DISPLAY XAUTHORITY=$XAUTHORITY KDE_SESSION_VERSION=5 KDE_FULL_SESSION=true dolphin
More: KDE Foruns - How to run Dolphin 18.08 as root with Kubuntu or KDE neon? - https://forum.kde.org/viewtopic.php?f=224&t=153655
Background:
Earlier - KDE Forums - How to run Dolphin as root?: https://forum.kde.org/viewtopic.php?f=224&t=141836
For the security reasons: Disallow executing Dolphin as root on Linux - https://cgit.kde.org/dolphin.git/commit/?id=0bdd8e0b0516555c6233fdc7901e9b417cf89
Disallow executing Dolphin as root on Linux Basically a copy of commit
kate/9adcebd3c2e476c8a32e9b455cc99f46b0e12a7e which was written by
Martin Grässlin
Disallow executing kate and kwrite as root on Linux: https://phabricator.kde.org/R40:9adcebd3c2e476c8a32e9b455cc99f46b0e12a7e
More tips
KDE Reddit - Dolphin root on KDE App 17.04 : https://www.reddit.com/r/kde/comments/6785b1/dolphin_root_on_kde_app_1704/
Bypass "Executing Dolphin as root is not possible" and Regain KDE Dolphin Root Privileges: https://www.reddit.com/r/kde/comments/6xs3mp/bypass_executing_dolphin_as_root_is_not_possible/
Future
Polkit support in KIO: https://phabricator.kde.org/T6561
When it is ready the Dolphin will show the password query if needed. Now, with the patched Dolphin&KIO:
Short:
Dolphin 17.04
The Dolphin 17.04 or later has a check:
if uid == 0 then show the "Executing Dolphin as root is not possible." and exit.
A workaround
You could edit the sources and disable the check. Then the Dolphin will work as before.
Dolphin 18.08
Few review request
Re-allow running Dolphin as the root user (but still not using sudo): https://phabricator.kde.org/D12795
Show a warning when running as the root user: https://phabricator.kde.org/D12732
Dolphin 18.08.0 is using these changes and the Dolphin can be launched with the pkexec command as the administrative super user.
pkexec env DISPLAY=$DISPLAY XAUTHORITY=$XAUTHORITY KDE_SESSION_VERSION=5 KDE_FULL_SESSION=true dolphin
More: KDE Foruns - How to run Dolphin 18.08 as root with Kubuntu or KDE neon? - https://forum.kde.org/viewtopic.php?f=224&t=153655
Background:
Earlier - KDE Forums - How to run Dolphin as root?: https://forum.kde.org/viewtopic.php?f=224&t=141836
For the security reasons: Disallow executing Dolphin as root on Linux - https://cgit.kde.org/dolphin.git/commit/?id=0bdd8e0b0516555c6233fdc7901e9b417cf89
Disallow executing Dolphin as root on Linux Basically a copy of commit
kate/9adcebd3c2e476c8a32e9b455cc99f46b0e12a7e which was written by
Martin Grässlin
Disallow executing kate and kwrite as root on Linux: https://phabricator.kde.org/R40:9adcebd3c2e476c8a32e9b455cc99f46b0e12a7e
More tips
KDE Reddit - Dolphin root on KDE App 17.04 : https://www.reddit.com/r/kde/comments/6785b1/dolphin_root_on_kde_app_1704/
Bypass "Executing Dolphin as root is not possible" and Regain KDE Dolphin Root Privileges: https://www.reddit.com/r/kde/comments/6xs3mp/bypass_executing_dolphin_as_root_is_not_possible/
Future
Polkit support in KIO: https://phabricator.kde.org/T6561
When it is ready the Dolphin will show the password query if needed. Now, with the patched Dolphin&KIO:
edited Aug 23 '18 at 6:24
answered Dec 29 '17 at 20:09
user26687user26687
12.2k12432
12.2k12432
Could you elaborate a little bit more on the "For the security reasons"?
– Jim McAdams
Feb 26 '18 at 21:21
Did you read the phabricator.kde.org/… . Same / more : Martin Grässlin - Editing files as root: blog.martin-graesslin.com/blog/2017/02/editing-files-as-root
– user26687
Mar 5 '18 at 9:47
so, the simple answer is "you cannot run Dolphin as root, unless you install a patched version"?
– user47206
Jun 22 '18 at 9:56
add a comment |
Could you elaborate a little bit more on the "For the security reasons"?
– Jim McAdams
Feb 26 '18 at 21:21
Did you read the phabricator.kde.org/… . Same / more : Martin Grässlin - Editing files as root: blog.martin-graesslin.com/blog/2017/02/editing-files-as-root
– user26687
Mar 5 '18 at 9:47
so, the simple answer is "you cannot run Dolphin as root, unless you install a patched version"?
– user47206
Jun 22 '18 at 9:56
Could you elaborate a little bit more on the "For the security reasons"?
– Jim McAdams
Feb 26 '18 at 21:21
Could you elaborate a little bit more on the "For the security reasons"?
– Jim McAdams
Feb 26 '18 at 21:21
Did you read the phabricator.kde.org/… . Same / more : Martin Grässlin - Editing files as root: blog.martin-graesslin.com/blog/2017/02/editing-files-as-root
– user26687
Mar 5 '18 at 9:47
Did you read the phabricator.kde.org/… . Same / more : Martin Grässlin - Editing files as root: blog.martin-graesslin.com/blog/2017/02/editing-files-as-root
– user26687
Mar 5 '18 at 9:47
so, the simple answer is "you cannot run Dolphin as root, unless you install a patched version"?
– user47206
Jun 22 '18 at 9:56
so, the simple answer is "you cannot run Dolphin as root, unless you install a patched version"?
– user47206
Jun 22 '18 at 9:56
add a comment |
Not an answer, just a workaround for the purpose mentioned by the OP (copying or deleting files
).
The idea is to
install another file manger that doesn't have that limitation and that doesn't bring a lot of dependencies
create an "Open as root" context menu in Dolphin for this other file manager.
The main file managers of other desktops can be used (Nautilus, Nemo, Caja, Thunar) but they do bring some dependencies. Even PCManFM and PCManFM-Qt do that. If you need one of those for some other purpose adding that one could be a good solution.
I have found that Krusader (which I think in the past used to be installed by default in some KDE systems) can be easily installed, brings no dependencies in Kubuntu 18.04, and can be used as root.
sudo apt install krusader
Under its Tools it has the "Root" option.
which asks for password in a gui.
To add a context menu in dolphin, create the folder ~/.local/share/kservices5/ServiceMenus
and then do
kate ~/.local/share/kservices5/ServiceMenus/filemanager_root.desktop
and add
[Desktop Action root]
Exec=/usr/lib/kde4/libexec/kdesu krusader
Icon=dolphin
Name=Open in Krusader file manger as administrator
[Desktop Entry]
Actions=root
Icon=krusader_root
MimeType=inode/directory
ServiceTypes=KonqPopupMenu/Plugin
Type=Service
X-KDE-Priority=TopLevel
X-KDE-StartupNotify=false
For some reason kdesu krusader
doesn't work, and I have used the solution from here.. What also works is konsole -e sudo krusader
, but that shows the terminal instead of a gui for the password prompt.
Then, you'll see in Dolphin:
bringing a dialog
which is one that works..
add a comment |
Not an answer, just a workaround for the purpose mentioned by the OP (copying or deleting files
).
The idea is to
install another file manger that doesn't have that limitation and that doesn't bring a lot of dependencies
create an "Open as root" context menu in Dolphin for this other file manager.
The main file managers of other desktops can be used (Nautilus, Nemo, Caja, Thunar) but they do bring some dependencies. Even PCManFM and PCManFM-Qt do that. If you need one of those for some other purpose adding that one could be a good solution.
I have found that Krusader (which I think in the past used to be installed by default in some KDE systems) can be easily installed, brings no dependencies in Kubuntu 18.04, and can be used as root.
sudo apt install krusader
Under its Tools it has the "Root" option.
which asks for password in a gui.
To add a context menu in dolphin, create the folder ~/.local/share/kservices5/ServiceMenus
and then do
kate ~/.local/share/kservices5/ServiceMenus/filemanager_root.desktop
and add
[Desktop Action root]
Exec=/usr/lib/kde4/libexec/kdesu krusader
Icon=dolphin
Name=Open in Krusader file manger as administrator
[Desktop Entry]
Actions=root
Icon=krusader_root
MimeType=inode/directory
ServiceTypes=KonqPopupMenu/Plugin
Type=Service
X-KDE-Priority=TopLevel
X-KDE-StartupNotify=false
For some reason kdesu krusader
doesn't work, and I have used the solution from here.. What also works is konsole -e sudo krusader
, but that shows the terminal instead of a gui for the password prompt.
Then, you'll see in Dolphin:
bringing a dialog
which is one that works..
add a comment |
Not an answer, just a workaround for the purpose mentioned by the OP (copying or deleting files
).
The idea is to
install another file manger that doesn't have that limitation and that doesn't bring a lot of dependencies
create an "Open as root" context menu in Dolphin for this other file manager.
The main file managers of other desktops can be used (Nautilus, Nemo, Caja, Thunar) but they do bring some dependencies. Even PCManFM and PCManFM-Qt do that. If you need one of those for some other purpose adding that one could be a good solution.
I have found that Krusader (which I think in the past used to be installed by default in some KDE systems) can be easily installed, brings no dependencies in Kubuntu 18.04, and can be used as root.
sudo apt install krusader
Under its Tools it has the "Root" option.
which asks for password in a gui.
To add a context menu in dolphin, create the folder ~/.local/share/kservices5/ServiceMenus
and then do
kate ~/.local/share/kservices5/ServiceMenus/filemanager_root.desktop
and add
[Desktop Action root]
Exec=/usr/lib/kde4/libexec/kdesu krusader
Icon=dolphin
Name=Open in Krusader file manger as administrator
[Desktop Entry]
Actions=root
Icon=krusader_root
MimeType=inode/directory
ServiceTypes=KonqPopupMenu/Plugin
Type=Service
X-KDE-Priority=TopLevel
X-KDE-StartupNotify=false
For some reason kdesu krusader
doesn't work, and I have used the solution from here.. What also works is konsole -e sudo krusader
, but that shows the terminal instead of a gui for the password prompt.
Then, you'll see in Dolphin:
bringing a dialog
which is one that works..
Not an answer, just a workaround for the purpose mentioned by the OP (copying or deleting files
).
The idea is to
install another file manger that doesn't have that limitation and that doesn't bring a lot of dependencies
create an "Open as root" context menu in Dolphin for this other file manager.
The main file managers of other desktops can be used (Nautilus, Nemo, Caja, Thunar) but they do bring some dependencies. Even PCManFM and PCManFM-Qt do that. If you need one of those for some other purpose adding that one could be a good solution.
I have found that Krusader (which I think in the past used to be installed by default in some KDE systems) can be easily installed, brings no dependencies in Kubuntu 18.04, and can be used as root.
sudo apt install krusader
Under its Tools it has the "Root" option.
which asks for password in a gui.
To add a context menu in dolphin, create the folder ~/.local/share/kservices5/ServiceMenus
and then do
kate ~/.local/share/kservices5/ServiceMenus/filemanager_root.desktop
and add
[Desktop Action root]
Exec=/usr/lib/kde4/libexec/kdesu krusader
Icon=dolphin
Name=Open in Krusader file manger as administrator
[Desktop Entry]
Actions=root
Icon=krusader_root
MimeType=inode/directory
ServiceTypes=KonqPopupMenu/Plugin
Type=Service
X-KDE-Priority=TopLevel
X-KDE-StartupNotify=false
For some reason kdesu krusader
doesn't work, and I have used the solution from here.. What also works is konsole -e sudo krusader
, but that shows the terminal instead of a gui for the password prompt.
Then, you'll see in Dolphin:
bringing a dialog
which is one that works..
edited Jun 25 '18 at 7:17
answered Jun 22 '18 at 13:02
user47206
add a comment |
add a comment |
I have made my own version based on the replies above.
So, to add a context menu to open Dolphin as root follow these steps:
- Create a file called for example
DolphinAsRoot.desktop
on the directory~/.local/share/kservices5/ServiceMenus/
- With a text editor put the following content on it:
[Desktop Entry]
Actions=root
Icon=system-file-manager-root
MimeType=inode/directory
ServiceTypes=KonqPopupMenu/Plugin
Type=Service
X-KDE-Priority=TopLevel
X-KDE-StartupNotify=false
[Desktop Action root]
Exec=/usr/bin/pkexec env DISPLAY=$DISPLAY XAUTHORITY=$XAUTHORITY KDE_SESSION_VERSION=5 KDE_FULL_SESSION=true dolphin
Icon=system-file-manager-root
Name=Open as administrator
- If it still not appears on the context menu in Dolphin go to "Settings -> Configure Dolphin...-> Services" and activate the option you recently added. It should be there. If not, close Dolphin or even log out and in on your session.
That's all, I hope it helps you all like it helped me ;)
add a comment |
I have made my own version based on the replies above.
So, to add a context menu to open Dolphin as root follow these steps:
- Create a file called for example
DolphinAsRoot.desktop
on the directory~/.local/share/kservices5/ServiceMenus/
- With a text editor put the following content on it:
[Desktop Entry]
Actions=root
Icon=system-file-manager-root
MimeType=inode/directory
ServiceTypes=KonqPopupMenu/Plugin
Type=Service
X-KDE-Priority=TopLevel
X-KDE-StartupNotify=false
[Desktop Action root]
Exec=/usr/bin/pkexec env DISPLAY=$DISPLAY XAUTHORITY=$XAUTHORITY KDE_SESSION_VERSION=5 KDE_FULL_SESSION=true dolphin
Icon=system-file-manager-root
Name=Open as administrator
- If it still not appears on the context menu in Dolphin go to "Settings -> Configure Dolphin...-> Services" and activate the option you recently added. It should be there. If not, close Dolphin or even log out and in on your session.
That's all, I hope it helps you all like it helped me ;)
add a comment |
I have made my own version based on the replies above.
So, to add a context menu to open Dolphin as root follow these steps:
- Create a file called for example
DolphinAsRoot.desktop
on the directory~/.local/share/kservices5/ServiceMenus/
- With a text editor put the following content on it:
[Desktop Entry]
Actions=root
Icon=system-file-manager-root
MimeType=inode/directory
ServiceTypes=KonqPopupMenu/Plugin
Type=Service
X-KDE-Priority=TopLevel
X-KDE-StartupNotify=false
[Desktop Action root]
Exec=/usr/bin/pkexec env DISPLAY=$DISPLAY XAUTHORITY=$XAUTHORITY KDE_SESSION_VERSION=5 KDE_FULL_SESSION=true dolphin
Icon=system-file-manager-root
Name=Open as administrator
- If it still not appears on the context menu in Dolphin go to "Settings -> Configure Dolphin...-> Services" and activate the option you recently added. It should be there. If not, close Dolphin or even log out and in on your session.
That's all, I hope it helps you all like it helped me ;)
I have made my own version based on the replies above.
So, to add a context menu to open Dolphin as root follow these steps:
- Create a file called for example
DolphinAsRoot.desktop
on the directory~/.local/share/kservices5/ServiceMenus/
- With a text editor put the following content on it:
[Desktop Entry]
Actions=root
Icon=system-file-manager-root
MimeType=inode/directory
ServiceTypes=KonqPopupMenu/Plugin
Type=Service
X-KDE-Priority=TopLevel
X-KDE-StartupNotify=false
[Desktop Action root]
Exec=/usr/bin/pkexec env DISPLAY=$DISPLAY XAUTHORITY=$XAUTHORITY KDE_SESSION_VERSION=5 KDE_FULL_SESSION=true dolphin
Icon=system-file-manager-root
Name=Open as administrator
- If it still not appears on the context menu in Dolphin go to "Settings -> Configure Dolphin...-> Services" and activate the option you recently added. It should be there. If not, close Dolphin or even log out and in on your session.
That's all, I hope it helps you all like it helped me ;)
answered Feb 15 at 18:36
Juan Gómez CarrilloJuan Gómez Carrillo
11115
11115
add a comment |
add a comment |
Thanks for contributing an answer to Ask Ubuntu!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f990611%2fhow-to-run-dolphin-as-root%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
What version of Ubuntu are you using?
– George Udosen
Dec 29 '17 at 17:38
1
are you using wayland? by default wayland does not allow GUI programs to run as root.
– ravery
Dec 29 '17 at 17:42
doesn't work. the option to create or move files is simply greyed out in the context menu. Please check your version
– Ankur S
Dec 29 '17 at 17:51
I'm using ubuntu 17.10 and x11 with kde installed
– Ankur S
Dec 29 '17 at 17:56
2
"So how can I run dolphin as root for copying or deleting files?" Please re-evaluate this question. Use command line for admin tasks. It is there specifically for admin tasks. Graphical tools should not be used for admin tasks. Running graphical tools as admin has unseen side effects regarding permissions and as of late is deemed such that the developers actively block it. Do you really think it is a good idea to go against the people that know (or are supposed to know ;) ) exactly what a graphical files manipulation tool can and does?
– Rinzwind
Dec 29 '17 at 20:23