Manipulating files owned by root in GUI.

I believe you may have lacked enough coffee - or I have had too much coffee...

I believe our esteemed colleague meant 'file manager'.
code/ @RADIO-SH81R:~$ sudo /bin/pcmanfm-qt /code
was the magic incantation, unfortunately it runs but you can't do anything.

But thanks anyway

GeoffinOz
 


G'day Geoff and welcome to linux.org :)

I want this to be as easy as it is in Windows.

Won't happen, mate. They can be as different as chalk and cheese, or it's comparing apples to oranges, at best.

You need to employ a different mindset.*

I can put on your Distro this weekend, and then you have someone local at your back.

I don't do the radio stuff, but we have a couple of radio enthusiasts here I can flag this to.

You will be better off addressing the radio issue in a separate thread, likely under General LInux Questions, otherwise the waters here will get muddied.

* You could have a read of https://linux.oneandoneis2.org/LNW.htm to see what I meant, above.

BTW - I am from near Stanthorpe, near the Qld/NSW border.

Cheers

Chris Turner
wizardfromoz
 
G'day Geoff and welcome to linux.org :)



Won't happen, mate. They can be as different as chalk and cheese, or it's comparing apples to oranges, at best.

You need to employ a different mindset.*

I can put on your Distro this weekend, and then you have someone local at your back.

I don't do the radio stuff, but we have a couple of radio enthusiasts here I can flag this to.

You will be better off addressing the radio issue in a separate thread, likely under General LInux Questions, otherwise the waters here will get muddied.

* You could have a read of https://linux.oneandoneis2.org/LNW.htm to see what I meant, above.

BTW - I am from near Stanthorpe, near the Qld/NSW border.

Cheers

Chris Turner
wizardfromoz
Thanks mate. I'm aware they're different and largely why, but simple things (like moving and renaming a file that needs to go to an area owned by root) are very tedious, require a lot of manual entry and take ten times as long to do in Linux than in Windows. And that's very frustrating. I'm not used to the operating system preventing me from making necessary changes, particularly when it's simply a file move or rename, not to mention editing text files from a terminal which is slow torture.

Appreciate your time with this. I've got a handle on the radio stuff pretty much, I've worked in the tech area, one way or another (initially in TV stations) that isn't a problem for me. But Linux seems to fight you every inch of the way - the simplest of things are complex or at best obscure. Getting scroll up down arrows to appear in Libre Office Writer being a case in point. That was ridiculously complicated. Now this. I guess I'll learn but I absolutely hate the text editors forced on you by need to use sudo in a terminal to do anything useful.

Port Pirie, about 225km NNW of Adelaide.

I suppose I'm used to using Windows as Administrator the entire time for many years, and what I wanted to do would literally take thirty seconds in windows, instead it was most of twenty minutes just figuring out how to do it and then having to type by hand tedious long paths and filenames into a command line util I'd never even heard of (mv - for some reason cp didn't seem to show up first time I tried) then having to do it all again because I forgot to put 'sudo' in front of it.

The trick with running the resident file manager with sudo didn't work. More precisely it ran, but it wouldn't let you do anything - 'Unsupported operation' couldn't even browse the file system. No idea why. I'm also a little surprised there isn't a 'root shell' instead of sudo or perhaps as well, to make this sort of thing at least a little easier. I guess I expect to be able to use user friendly gui apps to do trivial things, however Linux seems to have a law against it. As to the text editing. The command line editor in VMS was much easier to use - that system had no gui - but I'd sometimes use DECNet to share the files to a Windows box and login as SYSTEM to edit files in a proper gui editor. That was a little tricky as VMS does file versioning by default, but it was doable and a bit easier than the text editor. I'm using nano at the moment, but if there's something less nasty about for terminal I'd be pleased to hear of it, not sure what the default one in this distro is but it's truly ugly.

Thanks for your help, it's appreciated.


Regards

GeoffinOz
 
Hi,

my proposal is
  • install geany (gtk text editor)
  • open geany as sudo
Code:
sudo geany
  • Use file => open dialog to open your destination file
  • Do your changes
  • Save
  • Close geany
Ok, I'll try that, nothing to lose as this stage. A file manager that will run with sudo would be great too. After much looking and poking, this seems to be Lubuntu under the hood.

Thanks.

GeoffinOz
 
Hi,

my proposal is
  • install geany (gtk text editor)
  • open geany as sudo
Code:
sudo geany
  • Use file => open dialog to open your destination file
  • Do your changes
  • Save
  • Close geany
Ok, installed via Muon Package Manager. Throws up a stack of icon related errors in the terminal when run with sudo, however it seems to work, I can open a file and save it even if it belongs to root. Can likely rename a text file by doing save as, but obviously it doesn't do copy, move or rename on binaries. But it's a start, thank you for that.

Regards

GeoffinOz
 
G'day Geoff and welcome to linux.org :)



Won't happen, mate. They can be as different as chalk and cheese, or it's comparing apples to oranges, at best.

You need to employ a different mindset.*

I can put on your Distro this weekend, and then you have someone local at your back.

I don't do the radio stuff, but we have a couple of radio enthusiasts here I can flag this to.

You will be better off addressing the radio issue in a separate thread, likely under General LInux Questions, otherwise the waters here will get muddied.

* You could have a read of https://linux.oneandoneis2.org/LNW.htm to see what I meant, above.

BTW - I am from near Stanthorpe, near the Qld/NSW border.

Cheers

Chris Turner
wizardfromoz
One other thing, I actually manage several web and mail servers on leased Centos or CloudLinux systems, but almost never use terminal to do so, because WHM and CPanel were invented to make it easier.

I read the link you supplied and agree with some of it. I get that Win and Linux are not the same and never will be, I've used other OS that were heavily (or entirely) command line, but they were much easier than anything in Linux. (DOS editor that was in Dos 6.x was easy and even let you use a mouse.) I just want some simple tasks to be easier and I see no sensible reason they should be so hard. I'll have to disagree about the author's support for Vi(le) I've met it before and it's not just user unfriendly, it's hostile and I've no interest in dealing with it. None. Gui based text editors were created because of crawling horrors like Vi(le) and I'd simply like to be able to use one where I can scroll around the whole file, pick and remove, edit or just delete stuff instead of six lines at a time in a terminal with strange command keys required. In Windoze the only ones I've ever had to use are Ctrl C and Ctrl V, anything more exotic I haven't used since Ctrl KD in CP/M. However, someone suggested geany and that seems to work when run with sudo, throws up a stack of (icon related) errors in terminal, but it's usable so that's a big help.

Thanks

GeoffinOz
 
It's actually at version 30.x now. And yes, it's very good, and works a treat with USB SDR radio devices and does a whole range of things.

Well beyond 'tubes' (we call them valves outside the USA actually) and computers play a huge part, there's a whole range of digital modes, starting with the AX25 packet and a host of low signal stuff that can extract message from what sounds like just random noise. $50 for a half decent SDR receiver and an I5 from a few years back with 8gb of ram or so (though I've done it with a Core2 duo in 4gb and it still works) and you'd be surprised what you can do. I intercept and occasionally recover radiosondes this way.

GeoffinOz
Thanks for the update and reminder of naming conventions (tubes vs. valves). One of my siblings had a Kenwood TS-520 transceiver in the 1960s or early 1970s here in the US. They still have one of the old "Advanced" amateur radio licenses, which were deprecated a long time ago.

Do not ask me how I managed to pull those memories out of my ... (It was kind'a scary, actually.)

I will look into software defined radios when I get a chance. Learning never stops. Welcome to Linux.org, by the way!
 
Hello @GeoffinOz,
Welcome to Linux.org forums,
DragonOS is based on Lubuntu. and the correct command in terminal to open file manager is
Code:
sudo pcmanfm-qt
You could add an entry to the main menu using that command if you wish. but install alacarte menu editor.
God to discover and search for alacarte. once install launch it and add an entery for pcmanfm -qt (root)
with the above command. I know it seem complicated but Lubuntu is a light weight desktop and requires a lot of manual effort to make changes.
In any event DragonOS is a nice distro for ham ops. I don't own any SDR radios at the moment but if I did would mostly be using Dragon myself.

There is another Hamradio distro also by Andy KB1OIQ - found here, which you may want to look at also.
Enjoy the journey! :)
73, Dave KC1DI
 
Hello @GeoffinOz,
Welcome to Linux.org forums,
DragonOS is based on Lubuntu. and the correct command in terminal to open file manager is
Code:
sudo pcmanfm-qt
You could add an entry to the main menu using that command if you wish. but install alacarte menu editor.
God to discover and search for alacarte. once install launch it and add an entery for pcmanfm -qt (root)
with the above command. I know it seem complicated but Lubuntu is a light weight desktop and requires a lot of manual effort to make changes.
In any event DragonOS is a nice distro for ham ops. I don't own any SDR radios at the moment but if I did would mostly be using Dragon myself.

There is another Hamradio distro also by Andy KB1OIQ - found here, which you may want to look at also.

Enjoy the journey! :)
73, Dave KC1DI
Hi Dave,

I did try that, it runs, but it won't even let your browse. Someone else mentioned geany and that seems to work. Both throw up errors in terminal, but geany will let you edit stuff. I'm still looking for a gui file manager that doesn't break when you try and run it from sudo.

I have a couple of RTL-SDR USB clones, seem to work pretty well. Perhaps not as sensitive as I'd like, but not bad for the price (around $30AU). I've had a brief look at KB1OIQ's distro, it's not bad but had some issues with it that were likely related to the (marginal) hardware, so I'm going to give it another run on an I5 with more RAM and see how we go. When I get around to renewing my (Advanced Class) ham license (just the money is the issue) I'll probably look at a Hack-RF or one of the SDR based HF transceivers. All QRP stuff, but it seems that's where it's all heading at the moment.

Dragon seems to be very much leading edge, and there are frequent updates, there's a youtube channel where he puts it through its paces too. https://www.youtube.com/@cemaxecuter7783
Well worth a look.

73 Geoff (was VK5GDR)
 
I'm still looking for a gui file manager that doesn't break when you try and run it from sudo.

I think you may have discovered a change in policy. It may well be some security-minded change.

But, don't worry, the option is there. It's just in the menu.

nlP9dBV.png
 
I think you may have discovered a change in policy. It may well be some security-minded change.

But, don't worry, the option is there. It's just in the menu.

nlP9dBV.png
Sadly, it doesn't work. Error box pops up. Big white cross on red background 'Operation not supported'. Seems they have deliberately broken it?

Correction, it DOES work, but you have to have browsed to root FIRST or you get the error message. Works just fine provided you do that first. Thank you!!!

Geoff

Regards
Geoff
 
Sadly, it doesn't work. Error box pops up. Big white cross on red background 'Operation not supported'. Seems they have deliberately broken it?

Regards
Geoff
both that option and sudo pcmanfm-qt work in a newly created virtual machine of DragonOS FocalX. it sounds like there might be something wrong behind the scenes on your install. if you run

journalctl -f
in a terminal before trying to open a root instance from the menu, do you get any errors or warnings about it?
 
both that option and sudo pcmanfm-qt work in a newly created virtual machine of DragonOS FocalX. it sounds like there might be something wrong behind the scenes on your install. if you run

journalctl -f
in a terminal before trying to open a root instance from the menu, do you get any errors or warnings about it?
No it's fine, it works. You just have to browse to root FIRST. Or it doesn't work. But I was able to move and rename files owned by root without issue with the root instance. Well done sir, thank you.

Regards

Geoff
 
having to type by hand tedious long paths and filenames into a command line util
bash (the default shell) has tab completion. if you type the first few letters and then hit tab, it may either finish the word or give you a list of options.
having to do it all again because I forgot to put 'sudo' in front of it.
sudo !! will rerun the previous command with sudo in front of it.
I'm also a little surprised there isn't a 'root shell' instead of sudo or perhaps as well, to make this sort of thing at least a little easier.
sudo -s will get you a root# prompt where you could complete multiple tasks requiring root authentication. running
exit will exit that prompt and put you back in your regular user's.
 
bash (the default shell) has tab completion. if you type the first few letters and then hit tab, it may either finish the word or give you a list of options.

sudo !! will rerun the previous command with sudo in front of it.

sudo -s will get you a root# prompt where you could complete multiple tasks requiring root authentication. running
exit will exit that prompt and put you back in your regular user's.
Ok, thank you so much for that, I've made note of all of it.

Thanks so much.

Regards

Geoff
 
you are quite welcome. it sounds like you are getting there :) good luck moving forward.
 
a couple of other possible productivity options with bash. the key combination Ctrl+R will open a (reverse-i-search): prompt where you can type a bit and search through your command history for a previous command. once you see the one you want, you can use the right arrow or Tab key to select it. then Enter would run it. the history command will output the previous commands you have run. ! plus the entry number will run that command. for example, !45 would run the 45th command in that list.
 
Hi Dave,

I did try that, it runs, but it won't even let your browse. Someone else mentioned geany and that seems to work. Both throw up errors in terminal, but geany will let you edit stuff. I'm still looking for a gui file manager that doesn't break when you try and run it from sudo.

I have a couple of RTL-SDR USB clones, seem to work pretty well. Perhaps not as sensitive as I'd like, but not bad for the price (around $30AU). I've had a brief look at KB1OIQ's distro, it's not bad but had some issues with it that were likely related to the (marginal) hardware, so I'm going to give it another run on an I5 with more RAM and see how we go. When I get around to renewing my (Advanced Class) ham license (just the money is the issue) I'll probably look at a Hack-RF or one of the SDR based HF transceivers. All QRP stuff, but it seems that's where it's all heading at the moment.

Dragon seems to be very much leading edge, and there are frequent updates, there's a youtube channel where he puts it through its paces too. https://www.youtube.com/@cemaxecuter7783
Well worth a look.

73 Geoff (was VK5GDR)
Hi Geoff,
Well hope your able to renew the license soon. I do only qrp here now. 2 watts or so Live in a retirement community and can not use outside antenna. Use small loop here. and have worked 30 or so countries so far.
I've been QRP for many years here. Worked qrp WAS and DXCC before I retired. Did some digital stuff But have been mostly CW man since my early year in Ham Radio 1965 or so. Hope we connect on the air some day.
73, dave
 
Hi Geoff,
Well hope your able to renew the license soon. I do only qrp here now. 2 watts or so Live in a retirement community and can not use outside antenna. Use small loop here. and have work 30 or so countries so far.
I've been QRP for many years here. Worked qrp WAS and DXCC before I retired. Did some digital stuff But have been most CW man since my early year in Ham Radio 1965 or so. Hope we connect on the air some day.
73, dave
Yeah, just retired myself, however it's my house and council here are used to antennas (city has a TV tower every third house I think). Hope to catch you on the air. Thanks for your help with this.

Regards

Geoff
 

Members online


Latest posts

Top