4 ms·
Yeah, I used to get very pissy about everything in windows being stashed in the registry but...how is that different from everything being hidden inside systemd
by hguant 5y ago
Yeah, I used to get very pissy about everything in windows being stashed in the registry but...how is that different from everything being hidden inside systemd, or in a /etc/config file that is silently changed by services?
- ayushnix 5y ago> in a /etc/config file that is silently changed by services? I'm not really invested in the Windows vs Linux thing but config files in /etc never get silently changed or removed. If they are, it's a critical bug, although I've never really seen it happen. If there are any updates to the service files, they'll be installed alongside the original file. For example, on Arch Linux, it'll be /etc/systemd/journald.conf.pacnew while the original journald.conf file will never be touched.
- aidenn0 5y agoDebian based systems will change some config files on updates; I had a systemd customization that was overwritten out from under me, and I evntually found there was one place for apt to manage and a different for me to manage.
- ayushnix 5y ago> Debian based systems will change some config files on updates; I had a systemd customization that was overwritten out from under me, and I evntually found there was one place for apt to manage and a different for me to manage. The only place where a package manager should overwrite changes is /usr. If you made any changes inside /usr, then yes, it'll be overwritten. A user isn't supposed to mess around inside /usr, unless there's a very good reason for it. There's /usr/local but it's better to just use $HOME/.local instead.
- aidenn0 5y agoIt's entirely possible it wasn't in /etc but somewhere else. This was a case of "I need to fix this urgently" and the first workaround I could find on stackoverflow suggested changing it in one place. After the problem came up again after an update I did a bit more digging to figure out where I could change it and apt would not overwrite it.
- oauea 5y agoapt will tell you the file was changed and ask you what to do (keep current, use new, show diff & merge). so you must've chosen to replace it, or used some gui updater that made the choice for you.
- floren 5y agoYou mean the scary prompts that I just mash "Y" on??? (can you tell that I've shipped Debian packages before?)
- goodpoint 5y agoNo, Debian always asks before overwriting anything in /etc and provides convenient options like showing a diff during the process.
- iso1210 5y agoOnly if you've changed from the default config file, and it's not anything in /etc, it's anything specified in the conffiles file in the .deb, which I believe should include things in /etc according to policy, but can include others (and doesn't have to include things in /etc if you ignore policy) And of course you can do anything you want in a postinst script (again setting aside policy)
- goodpoint 5y ago"setting aside policy" any software can do rm -rf / The whole point of Linux distributions is having policies to protect the end user and enforcing them.
- jart 5y agoHow long have you been using Linux? You've never had something like NetworkManager undo your edits to /etc/resolv.conf within microseconds? Control over DNS is like the hunger games of systems engineering. SystemD has probably taken over all the juicy stuff in /etc by now so I doubt newcomers would notice these days.
- ayushnix 5y ago> You've never had something like NetworkManager undo your edits to /etc/resolv.conf within microseconds? I've never really used NetworkManager on my personal setup but if you're using it, you are willingly giving control of your network settings inside /etc to it, including the DNS, which is why /etc/resolv.conf gets changed automatically. You can choose not to use NetworkManager or systemd-resolvd (while still using systemd) and they won't mess around with /etc/resolv.conf. For network management, I do use systemd-networkd and it hasn't overwritten or changed my files in /etc/systemd/network in the past 6 years of me using Linux, not that I recall at least.
- jart 5y agoMy will is to control my dns but unfortunately every software vendor wants to control it and leak it and intercept it too. Not much choice there. You should ask yourself what you're not seeing.
- ayushnix 5y agoIf it helps, I've installed AdGuard Home on a Raspberry Pi 4 and I've configured my router to make my devices use the RPi for DNS queries. This would ensure devices with DNS management services (Android) use the DNS I want. For devices that don't use DNS management services, I've changed /etc/resolv.conf manually to point it to my RPi and that file never gets modified automatically. It's upto you how you manage your settings in /etc. A software will never modify anything in /etc without your choice.
- jart 5y ago
- Beltalowda 5y agoThe big difference is that stuff in /etc/, ~/.config, etc. are discoverable and something that can be made sense of. The Windows registry is something I never really could make sense of. For example to change Caps Lock to be Ctrl you need to change "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Keyboard Layout\Scancode Map" to "hex:00,00,00,00,00,00,00,00,02,00,00,00,1d,00,3a,00,00,00,00,00". To disable that stupid Thumbs.db generation you change "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer\NoThumbnailCache" to "dword:00000001". These are for Windows 7, from my old files – may be different now. But how is anyone ever going to figure that out? xmodmap can be somewhat hard to use, but a least it's documented, and you can play around with it to discover stuff. Some random hex values in some registry thing? Yeah ... good luck with that.
- kllrnohj 5y agoFor thumbs.db isn't there just a UI option for it in the file explorer settings? But I think you're confusing "discoverable" with "I'm already familiar with one of them." There's really nothing discoverable about '/etc'. There's no consistency in structure or even what type of configuration files are used. And that isn't even the only configuration path! There's also the smattering of random hidden folder crap in your home directory and then also the Linux registry. Sorry I mean dconf. Meanwhile the windows registry is quite structured and strictly typed.
- Beltalowda 5y ago> For thumbs.db isn't there just a UI option for it in the file explorer settings? Maybe? It's possible I just used for convenience to quickly set up a machine. I haven't used Windows in over ten years, and I don't really recall; this is what I still have in my dotfiles repo "just in case I might need it in the future" (together with my old tcsh config and such, heh). The CapsLock/Ctrl thingy certainly wasn't a setting though. Most (not all, most) files in /etc and ~/.config are fairly decently documented and "obvious". You're right it's not consistent or ideal, but I do find it a lot better than Windows. I spent many years repairing Windows PCs for a living and spent plenty of time mucking about with the registry back in the day, and I never found it easy to work with, at all. I've forgotten more than I remember, but there's loads of odd things in there in odd locations. A big chunk of that is not the fault of Windows or Microsoft but the fault of applications though, and in that sense it's the same as Linux: getting all application developers to use your system consistently and how it's intended to be used turns out to be hard. For what it's worth, the registry would be much more palatable if it supported comments somehow (and if many things were actually commented!)