Description of problem: i had an iso of centos 6.2 on a remote box. i mounted it via -o loop then on the spacewalk server i used sshfs to mount it locally so that i may create the kickstartable distribution. no luck. it only worked when i mounted the iso locally -o loop on the spacewalk server. i am assuming this is also for nfs, altho untried Version-Release number of selected component (if applicable): How reproducible: Steps to Reproduce: 1. 2. 3. Actual results: Expected results: Additional info:
I assume the problem is SELinux related. What AVC denials do you get in audit.log?
Also, please specify exactly what "no luck" means -- if it's internal server error on .do page, show us traceback from /var/log/tomcat*/catalina.out.
hello re: selinux root@spacewalk ~]# getenforce Disabled re: the error: The initrd could not be found at the specified location: /media/images/pxeboot/initrd.img [root@spacewalk ~]# mount | grep media marafa.122.1:/mnt/iso on /media type fuse.sshfs (rw,nosuid,nodev) [root@spacewalk ~]# ls -ld /media/ drwxr-xr-x 1 root root 4.0K Dec 15 2011 /media/ last line in catalina.out 2012-06-28 04:13:50,511 [TP-Processor6] WARN com.redhat.rhn.frontend.action.channel.PackageSearchHelper - Performing pkg search: libpng-static, search_name 2012-06-28 04:13:50,928 [TP-Processor6] WARN com.redhat.rhn.frontend.action.channel.PackageSearchHelper - Performing pkg search: mod_nss, search_name [root@spacewalk ~]# date Thu Jun 28 06:14:59 EDT 2012
contents of the location mentioned above: [root@spacewalk log]# ll /media/images/pxeboot/initrd.img -rw-r--r-- 1 root root 30M Dec 10 2011 /media/images/pxeboot/initrd.img
command used to mount: sshfs marafa.122.1:/mnt/iso /media/
What does # runuser --shell /bin/bash tomcat 'ls -la /media/images/pxeboot/initrd.img' output?
root@spacewalk log]# runuser --shell /bin/bash tomcat 'ls -la /media/images/pxeboot/initrd.img' bash: ls -la /media/images/pxeboot/initrd.img: No such file or directory [root@spacewalk log]# ls -la /media/images/pxeboot/initrd.img -rw-r--r-- 1 root root 30M Dec 10 2011 /media/images/pxeboot/initrd.img
[root@spacewalk log]# runuser --shell /bin/bash tomcat 'sshfs marafa.122.1:/mnt/iso /media' bash: sshfs marafa.122.1:/mnt/iso /media: No such file or directory [root@spacewalk log]# runuser --shell /bin/bash tomcat `sshfs marafa.122.1:/mnt/iso /media` marafa.122.1's password: bash-4.1$ mount | grep media marafa.122.1:/mnt/iso on /media type fuse.sshfs (rw,nosuid,nodev) bash-4.1$ ls -la /media/images/pxeboot/initrd.img ls: cannot access /media/images/pxeboot/initrd.img: Permission denied bash-4.1$ cd /media bash: cd: /media: Permission denied bash-4.1$ cd / bash-4.1$ ls -ltr ls: cannot access media: Permission denied total 102 d?????????? ? ? ? ? ? media drwxr-xr-x. 2 root root 4096 Sep 23 2011 srv
(In reply to comment #7) > root@spacewalk log]# runuser --shell /bin/bash tomcat 'ls -la > /media/images/pxeboot/initrd.img' > bash: ls -la /media/images/pxeboot/initrd.img: No such file or directory > [root@spacewalk log]# ls -la /media/images/pxeboot/initrd.img > -rw-r--r-- 1 root root 30M Dec 10 2011 /media/images/pxeboot/initrd.img This means that whatever is in the chain of technologies that make that content available on your Spacewalk server is only making it available to the root user, not to the tomcat user. So it's a general access permission issue, not anything specific to Spacewalk. Closing as NOTABUG.