libera/#devuan/ Friday, 2018-12-28

AcaciaRandom question: Would it be a dumb idea to create a LVM volume group from a disk's partition + the entirety of another disk?01:17
Acaciause case is I'm going to have my home partition span most of one disk, aswell as all of a different disk I'm installing01:17
PinkBellyNaggerfuck systemd this shit is ruining my life13:49
PinkBellyNaggerIt makes me nervious even thinking about restarting my server (which is long overdue a reboot already)13:54
jonadabWhy on earth did you install systemd on a *server*?13:55
jonadabI wouldn't even install that malarke on a laptop.13:55
sixwheeledbeast^Systemd needs regular reboots to avoid the seemingly constant hack patching13:56
jonadabdefenestration, is what systemd needs.13:57
djphjonadab: funny, thats the same thing Windoes servers need.13:58
PinkBellyNaggerI'm moving to devuan once I have time to test it, run my use cases etc14:04
MinceRjust treat it like windows: install once, make image, reboot when it wants/needs to, reinstall from image when it breaks16:00
KatolaZAntoFox: you here?17:09
AntoFoxKatolaZ: hey17:56
AntoFoxyep17:56
wollHi18:52
gnarfacehi18:52
wollI copied a folder to /opt using "sudo cp", but I can only acess that folder as root.18:53
wollMy user is already in the sudoer group.18:53
amesserdo you need read or read/write access18:54
KatolaZwoll: cp -a18:54
rwpsudo cp and sudo cp -a will copy the source permissions too.  If you as a normal user can't read the original then you won't be able to read the copy either.18:59
gnarfacerwp: presumably he had access to it before, or he wouldn't be asking the question, but that's a good point19:00
gnarfacewell, that cp -a will, anyway19:00
rwpSo will the default cp without any options too.  Try a test!  sudo cp /etc/shadow /opt/ and then look at the result.  Be sure to clean up after the test.19:01
gnarfacesudo cp will actually not, i don't think.  the permissions should be clamped by umask in that case, and ownership would be changed to root, which combined with the default umask would remove everyone's access but root (as "sudoers" isn't a user)19:01
rwpthe umask only affects the mode bits.  Not the user and group.19:02
gnarfaceright, but that's irrelevant to my statement19:02
rwpBut the complaint was that after a sudo cp woll could only "access that folder as root".19:03
rwpI think that anything that requires that is fair game then. :-)19:03
woll"cp -a" copied the permissions too. But I still can't acess it with my regular user.19:04
gnarfacewoll: well do you have read permission on the parent directory?  you would naturally need that too19:04
KatolaZwoll: it means your regular user didn't have access before either19:04
rwpWhat is it that you are trying to do woll?  I mean the overall thing.  Not the low level copy thing.  Why do you want to do this copy?19:04
KatolaZyou also need x on dirs19:04
gnarfaceyea, true but only to list, not to access if you know the path directly19:05
amesserI'm currently restoring/rescuing data from an (very) old Fujitsu Siemens TX200 S4 Server. No further use for it (Tower, Dual Xeon E5430, 5x 2,5" 140GB SAS Disk at PCIe HW-Raid Controller, 3GB ECC Ram, Dual Hotwsap Powersupply). Anyone interessted in parts of it? (total weight of the whole box is arround 30 Kg)19:06
wollI have a jar file and a simple bash script to run it. The goal is to create a folder in /opt to store them, and create a launcher.19:06
wollI had acess to the folder before, but I accidently deleted it. Now I only have the one with root permission.19:07
amesserwoll i that case would make the folder/files owned by root, group root and give read/execute permissions for all19:07
rwpThanks for that!  It helps.  If you are copying a directory (you called it a folder, we call those directories) then you need to change the user, group, and permissions so you can access it.19:07
amesserchmod -R root:root /opt/<folder-name>19:08
amesserahh19:08
amesserwrong: correct: chown -R root:root19:08
KatolaZamesser: woll wants access for his/her user19:08
KatolaZnot for root19:08
rwpsudo chown -R woll:woll /opt/yourdirectory ; sudo chmod -R u+rw,g+rw,o+r,a+X /opt/yourdirectory19:08
KatolaZIIUC19:08
amesserthen chmod -R a+rX /opt/<folder>19:08
gnarfacedo you actually want X not x?19:09
amesserKatolaz: yep, but as long as only execute and read is required, i tend to have files under /opt owned by root19:10
rwpX is a very special permission action.  Best to read the real docs so I don't describe it incorrectly.19:10
gnarfacewoll: yea i guess it depends on if you want the user to be able to change stuff or just run the program...19:10
KatolaZamesser: we seem to be  a whole mile behind the issue of having all the files under /opt belonging to root here :)19:10
amesserok19:11
rwphttps://www.gnu.org/software/coreutils/manual/html_node/Conditional-Executability.html#Conditional-Executability19:11
gnarfacewoll: typically the user would have the ability to run programs from there but not change anything - you can do whatever you want but there are security risks for some choices19:11
rwpThe rationale is that it sets execute permission only on previously executable files and also on previously executable directories but does not turn everything executable.19:12
gnarfaceoh, that's handy19:13
wollgnarface: Exactly. I prefer for it to read and execute files.19:13
bahumbedbugo_O  who puts user files under /opt19:13
KatolaZbahumbedbug: please19:14
bahumbedbug?19:14
KatolaZwoll: is there a specific reason why you want that file under /opt?19:14
bahumbedbug /last woll19:14
bahumbedbugakc19:14
KatolaZbahumbedbug: woll has problems with setting permissions (chmod) so policy considerations are two meters above the problem here... ;)19:15
rwpSince /opt, and /srv, and some of those others are not described by the FHS then the local admin is allowed to do anything they wish there. Just like /usr/local.  It is often useful to put NPC user data such as www-data and similar things there.19:15
bahumbedbugstill confused, who would put user files under /opt though.. that is pretty silly.. almost as bad as /srv19:16
gnarfacehmmm.  why do i keep remembering /opt being in the debian FHS?19:16
rwpFor all I know it is a minecraft server installed there.  (shrug)19:16
gnarfaceoh, because it is https://wiki.debian.org/FilesystemHierarchyStandard19:16
wollKatolaZ: Organization.19:17
bahumbedbug /opt goes back a long, long time .. wouldn't surprise me  if debian got it wrong too.19:17
rwpIs it?  But no packages are allowed to install files there.19:17
gnarfacerwp: yes, it's specifically reserved for vendor stuff (extra-distro packages)19:17
KatolaZwoll: by policy, normally any file under /opt belongs to root or to a system user19:17
bahumbedbug /opt is optional software not part of the base distro/os, at least it was supposed to be.  Whatever the hell debian does is their own doing19:17
KatolaZbahumbedbug: this is the case19:18
KatolaZit's a jar19:18
KatolaZthat woll wants to launch from the desktop19:18
KatolaZit's third-party software19:18
KatolaZso it might well go under /opt/PACKAGENAME/19:18
bahumbedbugis it part of a package ?19:18
KatolaZit's a jar19:18
rwpIn the traditional unix systems such as HP-UX one often finds packaged software that installs there.  I think that is why the structure was propagated as optional into GNU/Linux distros too.19:18
KatolaZit's a java application19:19
KatolaZfrom somewhere19:19
KatolaZdoesn't matter IMHO19:19
KatolaZit would be good to have it under /opt/APPNAME/19:19
bahumbedbugkinda does19:19
wollI run that "chmod -R a+rX /opt/<folder>" command, this gave me the permissions, even after copying it to "/opt".19:20
gnarfacethe winehq packages do already follow it that way, as /opt/APPNAME/...19:20
wollKatolaZ: Indeed. A proper directory makes it even more tidy.19:20
bahumbedbugway I look at it is basically anything that can be installed standalone can go into /opt.  qt and wine for example.  Symlinks can be used after19:22
gnarfacei think there might be some precedent for /opt/VENDOR/APPNAME/19:22
bahumbedbugindeed there is.19:22
bahumbedbugyou can think of /opt as /usr or /usr/local from a linker perspective but it's not required (architecture directory convention for example doesn't need to be the same).19:23
KatolaZthere are many cases like that, indeed19:24
KatolaZstuff like matlab or mathematica, for instance, normally tries to go under /opt/VENDOR/APPNAME19:24
wollI have intelliJ installed. It also goes under /opt.19:25
bahumbedbuga lot of software that doesn't have formal packages does to not clobber existing systems19:27
bahumbedbugI wouldn't expect a distro provided release to do so19:28
KatolaZbahumbedbug: definitely19:28
KatolaZthat's the same reason why stuff under /opt normally belongs to root or to a system used19:29
KatolaZ~user19:29
bahumbedbugaye19:29
wollIs there a way to set the permissions of that user to any file or folder he copies from /opt to /home?19:30
wollJust to skip the command of granting permissions.19:31
bahumbedbugumask19:31
gnarfacefor normal users, when they copy the file from /opt to anywhere, the default ownership should be themselves19:33
wollgnarface: Even if I run it with a "sudo cp"?19:34
gnarfacewoll: no, because by default sudo is doing that as root19:35
gnarfacethat's the point of sudo19:35
gnarfacebut if the user can read a file, they don't need sudo to make a copy of it19:35
wollUnderstood, thanks.19:36
gnarfaceno problem19:36
redrickbahumbedbug: Funny thing, I have /opt -> /usr/local/opt on my systems, because I consider /opt redundant to /usr/local and basically a dumb proprietary-software idea.21:05
MinceRfunny, /opt holds free software just fine over here21:10
rwpThe /opt is really just another abstraction layer in the software.  It's just another layer.21:34
rwpJust remember that there isn't any problem in software that can't be solved by adding another layer.  Except the problem of having too many layers.21:34
redrickMinceR:  /opt's ability to hold free software doesn't change proprietary code having been the reason for its adoption, which was the minor portion of my point, the major one being it being redundant as well.22:07
MinceRi prefer not to mix different packages with each other and /opt is a pretty nice tool for avoiding that22:40
redrickIf there's a reason a symlink to directory /usr/local/opt doesn't do that exactly as /opt does, it's not evident to this easily confused sysadmin.  Are you perhaps just wanting to argue? #ArgumentClinic beckons.  ;->22:46
MinceRi'm not sure what the point of it is22:58
redrickOK, I'll add that to life's small disappointments.23:02
MinceRok23:25
redrickSyminking /opt to /usr/local/opt gets it off the root fs and places IMO like with like.23:54

Generated by irclog2html.py 2.17.0 by Marius Gedminas - find it at https://mg.pov.lt/irclog2html/!