LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 08-24-2016, 11:59 PM   #1
worsel
Member
 
Registered: Feb 2008
Location: Washington State, USA
Distribution: Slackware 14.2, Slackware-from-Scratch
Posts: 241

Rep: Reputation: 45
Slackware64-14.2 script problem


Had an accident about 10 days ago. Lost my home partition.
It was mostly backed up, so nothing important was lost.

After rebuilding, I found I could not run scripts, except in my home directory,
even if I owned the external directory.

Symptoms:
Run a bash script as ./<script> and all that happens is "Permission denied"

Run it as "bash <script>" (or "sh <script>" and it will run if there are no
functions in the script. Any function and again "Permission denied"

A google search turned up a similar problem in Slackware13, which was caused
by wrong permissions in glibc files, but a careful comparison with the file
permissions vs permissions shown in the manifest uncovered no problems there.

If anyone has any idea of what is wrong, please give me a clue.

TIA,

Worsel
 
Old 08-25-2016, 12:51 AM   #2
Wiser Slacker
Member
 
Registered: May 2014
Location: germany
Distribution: slackware x86_64 , arm , slackware , AlmaLinux
Posts: 83

Rep: Reputation: Disabled
what about the permissions of that files "-rwxr-xr-x" ?

what do you mean with functions ? functional script elements or calling to other scripts ?

what about your PATH and /etc/profile.d/ are there any changes ...

/etc/profile ...

.bash_profile or .bashrc ... and so on ?

hope you may get an idea ....
 
Old 08-26-2016, 05:28 AM   #3
camorri
LQ 5k Club
 
Registered: Nov 2002
Location: Somewhere inside 9.9 million sq. km. Canada
Distribution: Slackware 15.0, current, slackware-arm-currnet
Posts: 6,213

Rep: Reputation: 848Reputation: 848Reputation: 848Reputation: 848Reputation: 848Reputation: 848Reputation: 848
Did you have to re-create your user? If yes, is the UID of your user the same as before?
 
2 members found this post helpful.
Old 09-01-2016, 04:06 PM   #4
worsel
Member
 
Registered: Feb 2008
Location: Washington State, USA
Distribution: Slackware 14.2, Slackware-from-Scratch
Posts: 241

Original Poster
Rep: Reputation: 45
Sorry to be so long getting back to this, but I've had a few external problems,
mostly a grandson in the hospital with a ruptured appendix. He's out and healing
now, so I can get back to other things.

I have found the problem. Somehow my /etc/fstab file became corrupted. Visually it was
okay, but some partitions were mounted with wrong partions, as shown below:

Quote:
/dev/sda9 on / type ext4 (rw)
proc on /proc type proc (rw)
sysfs on /sys type sysfs (rw)
tmpfs on /dev/shm type tmpfs (rw)
/dev/sdb1 on /home type ext4 (rw)
/dev/sda1 on /boot/efi type vfat (rw)
/dev/sdc1 on /home/photos type ext4 (rw,noexec,nosuid,nodev) [PHOTOS]
/dev/sdc2 on /mnt/repos type ext4 (rw,noexec,nosuid,nodev) [REPOSITORY]
/dev/sdg1 on /mnt/sfs_basic type ext4 (rw,noexec,nosuid,nodev) [SFS_BASIC]
/dev/sdf1 on /mnt/backup type ext4 (rw,noexec,nosuid,nodev) [BACKUP]
/dev/sda5 on /mnt/lfs type ext4 (rw,noexec,nosuid,nodev) [LFS]
/dev/sda6 on /mnt/sfs type ext4 (rw,noexec,nosuid,nodev) [SFS]
/dev/sde1 on /mnt/xfr type ext4 (rw,noexec,nosuid,nodev) [XFR]
/dev/sdd1 on /home/Data1 type ext4 (rw,noexec,nosuid,nodev) [DATA1]
/dev/sdd2 on /home/Data2 type ext4 (rw,noexec,nosuid,nodev) [DATA2]
/dev/sdd3 on /home/Data3 type ext4 (rw,noexec,nosuid,nodev) [DATA3]
gvfsd-fuse on /home/jeg/.gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,user=jeg)
I edited fstab, retyping several lines, then rebooted. Now "mount -l" shows this:

Quote:
/dev/sda9 on / type ext4 (rw)
proc on /proc type proc (rw)
sysfs on /sys type sysfs (rw)
tmpfs on /dev/shm type tmpfs (rw)
/dev/sdb1 on /home type ext4 (rw)
/dev/sda1 on /boot/efi type vfat (rw)
/dev/sdc1 on /home/photos type ext4 (rw,noexec,nosuid,nodev) [PHOTOS]
/dev/sdc2 on /mnt/repos type ext4 (rw) [REPOSITORY]
/dev/sde1 on /mnt/sfs_basic type ext4 (rw,noexec,nosuid,nodev) [SFS_BASIC]
/dev/sdf1 on /mnt/backup type ext4 (rw,noexec,nosuid,nodev) [BACKUP]
/dev/sda5 on /mnt/lfs type ext4 (rw) [LFS]
/dev/sda6 on /mnt/sfs type ext4 (rw) [SFS]
/dev/sdg1 on /mnt/xfr type ext4 (rw,noexec,nosuid,nodev) [XFR]
/dev/sdh1 on /home/Data1 type ext4 (rw,noexec,nosuid,nodev) [DATA1]
/dev/sdh2 on /home/Data2 type ext4 (rw,noexec,nosuid,nodev) [DATA2]
/dev/sdh3 on /home/Data3 type ext4 (rw,noexec,nosuid,nodev) [DATA3]
gvfsd-fuse on /home/jeg/.gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,user=jeg)
REPOSITORY, LFS, and SFS partitions now allow scripts to run normally.
I'll mark this thread as closed.

Thanks to those who offered help!
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
alienBOB's vlc.Slackbuild script fails on libavcodec.pc on Slackware64 14.0 multilib. indubitableness Slackware 19 08-20-2013 07:37 AM
problem with slackware64 tinnnysu Slackware 7 10-14-2012 06:17 PM
Making rhythmbox work in Slackware64 13.1 -current: errors .. (helper script missing) GrapefruiTgirl Slackware 8 08-09-2010 05:08 AM
rrdtool configure script failure slackware64-13 fancylad Slackware 5 03-26-2010 09:52 AM
[SOLVED] Slackware64-C client wont detect Slackware64-C Samba server slackass Slackware 5 08-07-2009 11:23 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 01:33 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration