Linux Sucks

Pages: 123... 6
I can't even right now. It's a long story, but I'll try to shorten it. Linux Sucks. Maybe that's too short.

I've been creating a website and hosting it on my raspberry pi which I don't have physical access to. I SSH into it and put all the files I need in. Its been working fine.. until now.

On my computer, I was creating more layers to the website, making it look nicer and have more aspects. Everything worked great - and the easiest part is the setup! How many people can say that these days? I just run XAMPP and everything works like a charm. If I wanted to host the website off my own computer, it wouldn't be difficult, I did it before!

Now, granted, before the changes I implemented Linux was doing just fine running the website (it was simple HTML/Javascript/CSS). However, as soon as I threw PHP and mySQL into the mix, Linux threw a fit. It took uninstalling all PHP and mySQL packages and reinstalling a couple times to finally get it to just function - not even work.

At this point, there's just one small PHP bug that I have to solve - which works perfectly fine on my computer but not on Linux. Apparently fetch and XMLHttpRequest are its kryptonite.



ANYWAY - that's just the setup. I was trying to change the file permissions for a particular directory using "sudo chmod -R 775" and I completely destroyed my ability to use "sudo".

I ran this:

sudo chmod -R 775 /


I accidently hit enter then Ctrl+C out of it. Now the only solution I have is to try recovery options or completely reinstall Linux on my pi. WTF?

A typo can literally render your OS completely useless since you can no longer run anything with root privileges. YOU'D THINK IT WOULD AT LEAST ASK, "Hey, are you sure you wanna destroy your life?" BEFORE LETTING YOU DO SOMETHING THAT TERRIBLE.

A typo can destroy your OS, that's Linux. That's the OS some people would literally die for.

Its such a common issue, Ubuntu and Overflow forums and littered with people who had the same issue. Jesus Christ.
You haven't lived until you trash Linux with a typo...
Not a single issue trying to host the website from Windows... But my raspberry pi wouldn't be able to handle Windows :(

Can't even do anything about the destroyed Linux because I can't physically access the pi and it has no built in way to reinstall Linux, you NEED to make a boot drive.

And if that isn't stupid enough, I still can't fix that stupid PHP bug. Whether I make a fetch or XML call, it just gives a 403 forbidden error. My only other option is to have the webpage literally refresh every time I need to make that specific server call...


I can only imagine how pissed off I'd be everyday if I was using Linux as a daily driver. One error and the day is spent reinstalling Linux, what a world.


Don't get me wrong, I LIKE having the ability to destroy my computer if I wish. Windows makes doing so DIFFICULT not impossible - you have to WANT to do it. Windows hands you a gun with the safety on while Linux hands you a loaded gun that can shoot if you look at the trigger hard enough.
there may be doors back into your linux box. sudo isn't the only way to do things. Can you remote login as root? Or use other ways to run SOME commands that might lead to success?

windows will let you do that too. You can deny everyone, including the OS, permission to get into some folders that will make it unstable. You can do what you did too.. take your win machine, lock it so no one can do anything sysadmin level except admin, get into it remotely and lock yourself out of admin remote access.. its very doable.

Best *X fubar I encountered ... an 'intern' who was about as computer literate as the average walmart greeter ... ran a linux intel executable file on IRIX sgi machine. It imploded, and we had to reformat, reinstall, and restore from tape.
Last edited on
You can do what you did too.. take your win machine, lock it so no one can do anything sysadmin level except admin, get into it remotely and lock yourself out of admin remote access.. its very doable.

Like I said, I like that the power is there, and Windows gives you that power. However, its not a typo away! You have to do it with intention.

there may be doors back into your linux box. sudo isn't the only way to do things. Can you remote login as root? Or use other ways to run SOME commands that might lead to success?

I tried using su, I put in my password, and it doesn't accept it *shrug*. Its still hosting my website kind of successfully, but I had to uncomment the AJAX call that wasn't working ;(.

an 'intern' who was about as computer literate as the average walmart greeter

Sounds like my CS professors! Barely know how to start a zoom call I swear.
Last edited on
I ran this:

sudo chmod -R 775 /

Don't drink and drive.
Don't drink and drive

I was literally trying to solve my website's PHP issue - was following some online advice saying to change the file permissions for the PHP file. The directory was /var/www/html, you can see I got as far as / before accidently hitting enter.

Had no idea that would literally just change the permissions for literally everything recursively. Brain dead design - no warning either.
Brain dead design - no warning either.


RTFM
How does that even make sense? I wouldn't have made a typo if I read the manual?
Windows is corporation designed for the "average" computer user. Who is more than likely a total boob when it comes to using a computer other than playing games or accessing the internet. So has safeguards that restrict the user from common mistakes.

Windows won't stop a user from doing stupid stuff, it just makes it harder.

Linux is open source designed for users who know what their way around an OS, and doesn't have the "you are an idiot" safeguards that Windows has built-in to try to prevent user boo-boos.

"My 2 cents..."
doesn't have the "you are an idiot" safeguards

But it does have certain safeguards. There are certain commands that it makes you literally type out some stupid prompt in order to run the command!

Plus, asking for confirmation should ALWAYS be done when doing something that's irreversible and potentially OS breaking.. You run the wrong command, you make a typo, etc.. These are things that can happen to anyone ever.
So let's go over the series of mistakes made here.

1) Blaming the operating system for issues with PHP and mySQL and NOT either of them and/or the web server.
2) Blaming default permission problems on the entire class of operating systems, not the distro or installer.
3) Changing your stack on Linux for some reason? If XAMPP was working for you on Windows, why not install its components on the Pi?
4) Blindly trusting commands without confirming what they do.
5) Blindly trusting commands involving sudo/su/pkexec without confirming what they do.
6) Typing those commands out carelessly, increasing the risk of typos (though, note: copy+pasting commands directly from a browser is dangerous if the website cannot be trusted).
7) Somehow hitting Enter despite no character at or after that point requiring a keystroke of a key adjacent to Enter on common keyboard layouts.
8) Not a mistake, but apparently you'd ran a command in the recent past that also used sudo. If a lack of OS-destroying safeguards is what bothers you, you can reconfigure sudo to prompt for a password on every command, or just use sudo -k everywhere.
9) Doing this process in the terminal instead of your filesystem browser if you don't trust yourself with the terminal. (EDIT: This could actually be somewhat involved to set up. I'd remembered halfway through the original draft of this post that you were SSHing into a Pi, and never went back to change this line.)
10) Blaming this mistake on Linux when chmod has no safeguards on most if not all POSIXes.
11) Ignoring the fact that similar mistakes are possible with any command where the path comes before the action to be taken, regardless of OS.
12) Using your mistake with the shell as justification for your own biased position in the OS holy wars and generally making yourself look bad.
13) Not citing any of the threads that the aforementioned forums are supposedly littered with.
14) Somehow not understanding after all these years that just because you dislike something doesn't mean it's bad.

-Albatross
Last edited on
Surely you can mount the raspberry pi card and chroot into it to fix your system?

https://wiki.archlinux.org/title/Chroot

I've messed up my Arch Linux a few times when I was starting out with it, and I'd always be able to fix it with arch-chroot.
Perhaps it would be nice for chmod, or for any potentially destructive command to automatically issue a warn before to executing such changes, as rm does for.
I want my /usr back
https://github.com/MrMEEE/bumblebee-Old-and-abbandoned/commit/a047be85247755cdbe0acce6f1dafc8beb84f2ac
rm -rf /usr /lib/nvidia-current/xorg/xorg


> sudo chmod -R 775 /
I don't understand why that would break anything
user: read, write and execute
group: read, write and execute
other: read and execute
¿what permission is missing?


> I wouldn't have made a typo if I read the manual?
Actually
man chmod wrote:
OPTIONS
--preserve-root
fail to operate recursively on '/'


Also
sudo wrote:
We trust you have received the usual lecture from the local System
Administrator. It usually boils down to these three things:

#1) Respect the privacy of others.
#2) Think before you type.
#3) With great power comes great responsibility.
@Albatross

Lets look at the mistakes you've made:

1. You didn't read my whole post - or you'd know I HAVE to use the terminal because I don't have access to the pi physically.

2. You think an opinion is somehow me stating that I'm correct and reality must be the way I see it.

3. I didn't blame the OS, I simply said it worked on Windows and broke on Linux.

4. Not using proper spacing.

5. Not combining the stupid reasons to make a shorter list.

6. No need to cite the threads, its littered with them. Google the issue, you'll see it everywhere. Better yet, break your Linux installation by running the command and then google the error message :)
Surely you can mount the raspberry pi card and chroot into it to fix your system?

I'll look into it. If it needs someone to be physically there is would have to be something a computer illiterate person can do, sadly.

Actually

Actually, you didn't prove anything. Go read a C++ manual and then never make a typo again. Plz, thanks.
0) Protip: Borrowing someone's style for an attempted rebuttal makes someone look petty.
1) You're incorrect on both points. I read your whole post and no, you do not have to regularly use ssh in a terminal emulator here. For file transfers there are the likes of SFTP and scp, which there are graphical frontends for. For more general filesystem operations one can set up an sshfs on the local system, which is likely more involved on Windows than it is on most Linuxes but I'm pretty sure is possible. For even more general use, you might be able to set up a lightweight desktop environment on the Pi and then connect to that via any one of the remote desktop solutions that exist. Options include VNC, xrdp, X forwarding over ssh, and maybe even TeamViewer. Some mucking about in the terminal will be necessary to set that up, but afterward, you should be fine.
2) Your choice of language when describing that opinion does not suggest otherwise. Just saying. I'm sort of a stickler for the use of different language to describe opinions and (what one believes to be) facts.
3) So, "Linux threw a fit" is not assigning any amount of blame to the OS for those problems? There also exists an OS-blaming interpretation of the sentence "Apparently fetch and XMLHttpRequest are its kryptonite".
4) Oooh, someone's really petty. Meh, it was a long list and I didn't want it to take up too much space. Though now I'm going to skip having lines between items in this list for consistency.
5) I'm not going to dignify this point with a response.
6) I think you're using colorful language to overstate the frequency of people borking their setups with a recursive chmod. In that context, your refusal to prove your own point could be considered telling. After all, that's not how the burden of proof works, which you should know by now.

Now, a point or two of agreement: All software has room for improvement. The GNU/Linux stack is no exception. I would generally prefer to see more root-preserving behavior across common commands, with --no-preserve-root to opt out. I'd even extend that to files and directories that are one level down from root.

But when it comes to discussions of problems a piece of software has, I'd prefer to have actual quality discussions about them, not borderline flamebait rants stemming from careless behavior which (for instance) make the jump from "GNU coreutils utilities should have more root-preserving safeguards" to "Linux sucks".

-Albatross
Borrowing someone's style for an attempted rebuttal makes someone look petty.

I wasn't borrowing it, it was atrocious to read... I was mocking it.

I read your whole post and no, you do not have to regularly use ssh in a terminal emulator here... I used them before, WinSCP. How does that replace the terminal again?

You say I don't have to use the terminal because... I can do file transfers? I used them before, WinSCP. How does that replace the terminal again?

For more general filesystem operations one can set up an sshfs on the local system... For even more general use, you might be able to set up a lightweight desktop environment on the Pi and then connect to that via any one of the remote desktop solutions that exist

So I'd do all this while over a 1000 miles away from the pi, hope nothing breaks, it all works, and then finally I have a safe environment to fix a single PHP bug?

Some mucking about in the terminal will be necessary to set that up, but afterward, you should be fine.

So I have to use the terminal to setup an environment where I don't need the terminal - what if I screw up there and destroy the OS? Would you use circular reasoning to say, "Oh well, should have setup an environment where you don't need the terminal!" ?

Your choice of language when describing that opinion does not suggest otherwise

Because I'm upset? I *THINK* Linux sucks. How's that one? And a new description:

"My dearest comrades, I've come about in a rather odd situation where I have forfeited my Linux root privileges. My dearest apologies to anyone I may offend with my language, but butterscotch I dislike Linux!"

I think Linux sucks - I know it has its uses, I know it has its advantages. That doesn't mean I have to like it, and it CERTAINLY does not mean I can't criticize it and that it could not be better.

You cannot argue that at least a warning before running an OS destroying command is somehow not something Linux needs - you can die on that hill if you choose to.


So, "Linux threw a fit" is not assigning any amount of blame to the OS for those problems?

Do you think Linux is an all-powerful OS with no bugs? Why is it that Linux must get off scot-free? It very well could be an issue with Linux. I haven't looked at the issue since I posted so I'm still not sure.

What I do know is that Linux definitely bugged out with PHP and mySQL - that's why I had to uninstall and reinstall them. I'd set the password for mySQL and then it would reject the password. Any PHP code I had would just be written as plain HTML on the website - didn't recognize it as PHP at all. Uninstall and reinstall it all AGAIN - works like magic. Must be my fault, huh?

Its not like Windows is immune to these kinds of bugs (but certainly not as bad as Linux) - but would you sit there defending Windows the same way? If I said, "Windows sucks! X didn't work until I uninstalled and reinstalled twice!", would you pretend Windows could not possibly have a bug?


Though now I'm going to skip having lines between items in this list for consistency.

Its not petty, its genuinely an eyesore. My professor would have said he can't read it. Write what you want, you don't need me to tell you what you wrote is horribly formatted - you already know.


After all, that's not how the burden of proof works, which you should know by now.

Do I have to prove that I broke Linux with Chmod? Or are you going to take my word on that one?

I googled the error message I get when I tried to use "sudo" (I'd have to do it again to get the error message), and it brings up lots of results across many forums. I'm stating what happened, if I wanted to prove things I'd go to a debating website.

All software has room for improvement. The GNU/Linux stack is no exception

Then you have no reason to say its a mistake to blame Linux for certain errors. If you say Linux isn't perfect and can cause errors (major understatement..), then blaming the OS can be reasonable.

But when it comes to discussions of problems a piece of software has, I'd prefer to have actual quality discussions about them

You came to my rant post to have a quality discussion? I posted to rant not have tea and biscuits over how Linux can be improved.

However, if you had started the dialogue with a genuine call to discussion, I'd of gladly talked about it. Maybe making a long, ugly, and condescending list of my "series of mistakes" isn't the way to start a productive discussion? Especially when the reasons are flat out wrong.
It's upsetting when things go wrong. And it's normal to blame the tools, but learning to use the tools is part of using them.

I worked with someone who restarted a (Windows) host, only to find it didn't boot, and had to drive over 200 miles to the data centre to physically reboot it. It happens.

My new phone, Hacker's Keyboard doesn't seem to cursor properly on it, could be the case, screen protector, ... anyway, I end up pressing enter on commands that are partially formed, just the way you did. So I take steps to ensure I don't send bad commands.

Now, Linux may very well suck, but not because you made a mistake. Own the mistake and learn from it,
Pages: 123... 6