Segmentation fault when running anything after a failed upgrade to -current
SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Segmentation fault when running anything after a failed upgrade to -current
Sorry for the rather anecdotal nature of this message, but I feel like describing how I got in this mess will make it easier to find the solution to my rather bizarre symptoms.
Well, I went and did a stupid thing. My best friend was mocking me for still being on a 3.x kernel, and I decided to upgrade to -current. I followed all of the wiki instructions except the one about not upgrading your kernel, and when I rebooted my computer, everything looked fine - it identified as Linux 4.3, and I could log in and get a fortune message and use basic command line programs. However, when I tried to start X, it hung after failing to find a dynamic library. It seems something went wrong with install-new, and I didn't get some new dependencies, but the thing is, I'm not very experienced with Linux networking, so I use the Slackware default NetworkManager config to connect to my wireless router, which means I have to start X before my internet works. (I tried at one point to use the command line tools, but I couldn't get them to work.)
I got my Slackware 14.1 DVD that I installed with 3 months ago, mounted it, and changed my slackpkg mirrors file to point to it. When I tried to run slackpkg update, it claimed to succeed but nothing happened because awk was missing a dynamic library too. I used upgradepkg to install the old version of awk and tried again, and the command worked. This is where I started being really stupid. It was late at night and I was tired and I wanted to have my computer pretty much working again in the morning, so I ran slackpkg upgrade-all, completely forgetting about the warnings to upgrade slackpkg and glibc-solibs first. Needless to say, not long into the upgrade, packages stopped installing, and when slackpkg ended, every command I ran said that an Assert had failed. I gave up and forced my computer off. When I woke up in the morning and tried to log in, I got my fortune message, but no shell actually started. I booted off the DVD and tried to use slackpkg from there, but it was having trouble finding its config files so I had to chroot into my system. I decided to try using su - declan to see if I would get any more information than actually booting, but all I got was a segfault.
From the chroot, I upgraded every glibc-related package and slackpkg, then ran another upgrade-all, which failed because of a GPG error. I disabled GPG checking (hey, this is the same DVD I installed from in the first place) and ran it once more. The upgrade succeeded! I reran lilo as prompted and then rebooted into good ol' Linux 3.10.17. I logged in and got a bash shell. I typed startx. It segfaulted and I got logged out. So I logged back in and typed ls. Same thing.
So, to recap, after going to -current unsuccessfully and then going back to 14.1 even less successfully, every single command I run segfaults. If anyone could help me, that would be much appreciated because I'm having to post this from a spare computer running Windows 10, and I was not hoping to be reacquainted with Windows any time soon. I also have a lot of third-party packages on my system, and my home folder is too big to back up easily, so I don't want to reformat and reinstall unless that's the only way.
What I would try is to remove everything but /home /dev /proc /run and /sys then reinstall Slackware version 14.1, telling the installer to not format your root or / partition.
Al least that would preserve all you files in /home.
If you kept the third party packages you installed, just move them to /home before proceeding if they are elsewhere. And don't move to -current until you are really familiar with Slackware.
Last edited by Didier Spaier; 10-10-2015 at 05:43 PM.
I'm certain I don't need to completely reinstall, even if a LOT of packages need to be replaced. But I'm fairly sure I don't even need to do that. I was experimenting with the LiveCD chrooted into my actual system again and I got this when I ran su -l -c zsh declan:
So I'm guessing this would indicate that I've screwed up my system locale, which is a lot narrower of a problem to work with. Does anyone know how I can fix this without, er, going the Windows route?
could attempt to download the slackware packages that you think your missing to a local directory and install with installpkg or pkgtool, if the errors your getting occur with slackpkg.
could attempt to download the slackware packages that you think your missing to a local directory and install with installpkg or pkgtool, if the errors your getting occur with slackpkg.
I don't have missing packages anymore. I already inserted the disc and upgraded with it as a mirror.
Anyway, my friend told me I needed to have LANG set, so I made a shell script in profile.d called utf8hack.sh that sets it to LANG=en_US.utf8. Now, I can boot and run commands without segfaulting, but when I run xwmconfig, there's garbage data all over the screen. When I startx, my monitor goes black and my system hangs (I can't switch back to tty1 to see the error or anything, but I will check the log). I realised that my nvidia drivers were probably screwed up, so I reran the install script for them and they couldn't find my gpu anymore. I'm not typing very well because I'm terrified I'll have to reformat.
edit: I have an AMD card, that'd be why the nvidia drivers aren't working. I wonder why I never deleted them, and why I can't find the AMD ones.
edit2: right, I reran the AMD installer, and now X crashes saying that there is "No matching Device section" for any of the PCI addresses listed. I even copied my old config from April that worked fine on the exact same package base and card and it still doesn't work. I tried to use the > operator on startx but it wouldn't have it.
edit3: turns out my x config in my home folder was the culprit. I deleted all the x-related files and now I can get to xfce - kinda. I get my good ole desktop background but all my icon config is gone, I can see the files on my desktop (almost entirely steam shortcuts), I have a bottom panel, and if I open my home folder from its desktop shortcut, I get a window in the top-left corner that cannot be moved. In essence, I don't have a window manager. Upon quitting X with ctrl+alt+bksp, I get this:
Code:
xfsettingsd: Fatal IO error 11 (Resource temporarily unavailable) on X server :0.0.
xfdesktop: Fatal IO error 4 (Interrupted system call) on X server :0.0.
I think I need to delete some more config files, but I'm not sure where.
Last edited by ThatDude92194; 10-10-2015 at 11:50 PM.
Why not "adduser" from runlevel 3 to quickly see if the offending configs are in your current HOME?
PS - And tell your buddy that NEW!= IMPROVED. Unless there is some compelling reason, usually new or improved hardware support, kernel updates are incremental and those increments are commonly miniscule. AFAIK kernel 4x is not any manner of major improvement let alone paradigm shift over kernel 3x to warrant mockery.
This thread almost qualifies for a sticky as a reminder that as long as a Linux system boots, "wipe and reinstall" is unwarranted and the stuff of windows zombies and cowards. Yes, it is faster and easier to wipe and reinstall but understanding of one's mistakes and how linux works is priceless and a work in and of progress.
"wipe and reinstall" is unwarranted and the stuff of windows zombies and cowards
Finally, someone on the side of reason!
Anyway, I'll probably have to make a new thread, because everyone seems to be ignoring the significant progress I've made and trying to fix my initial symptoms. See ya, I'm outta here! *dissolves into a mess of squares*
Anyway, I'll probably have to make a new thread, because everyone seems to be ignoring the significant progress I've made and trying to fix my initial symptoms. See ya, I'm outta here! *dissolves into a mess of squares*
You did not.. Your problems do not come from system locales.. Emerson is probably right about glibc.. The problem is that if you don't know the state of your packages downloading and manually installing glibc is not guarantied to fix your problem... You however could check the logs and try to manually downgrade them all (basically revert) or try to finish your upgrade manually somehow.. But the more secure (and the for-dumbies) way is to revert to the stable pacakages from the dvd and then retry the update..
Off-course, this all depends on what experience you have and how many extra packages you already have (a clean-system would basically uninstall any extra package, but you can skip this)...
Since your kernel probably changed, your graphic drivers need to be reinstalled also... But don't try this until you are sure you have an otherwise fully operating system...
At least this is my view of what happened there from what you've shown us..
Come on, guys! I thought ya knew better. I'll stop referencing that now because it's even making me cringe.
But seriously, it WAS my system locale. You know how I know? Because I put a shell script in profile.d to set LANG and everything except X (and apparently ncurses, but it works, just with garbage data because I'm using UTF8 all of a sudden) magically worked again. I already said that. The upgrade finished successfully before I ever rebooted, so I know it didn't leave half-installed packages. Besides, I already got my old install DVD and replaced all the 14.1 packages.
MY ONLY PROBLEM RIGHT NOW IS X DOESN'T WORK. That's all. None of the symptoms in the OP are there anymore. I fixed it, and without a "wipe and install" either. I've removed the package serieses X, XAP, KDE, KDEI, and XFCE so that I can easily go through, delete leftover configs from /etc, and reinstall them good as new. If that doesn't work, I'll need help again, and I'll start a new thread because nobody is reading anything except the OP before they try to help.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.