Alfred von Campe
2007-Apr-23 21:39 UTC
[CentOS] Error trying to mount NFS volume from kickstart in CentOS 5
The post section of the kickstart configuration file I have been using in CentOS4 looks like this: %post mount centosmirror:/var/www/html/ks /mnt /mnt/ks/post/post.sh > /root/post_install.log 2>&1 umount /mnt I tried to do my first CentOS 5 kickstart installation today using an identical post section, but the post install script did not run. After instrumenting the kickstart a bit, I found that the above mount command failed with the following error message: mount.nfs: Input/output error Not a very helpful error message -- any clues as to what is going on? It's a little tricky and time consuming to debug kickstart problems like these, so I thought I'd ask the list and hopefully save some time. If I execute that mount command after rebooting the system, it works just fine. Thanks, Alfred
Alfred von Campe
2007-Apr-24 15:35 UTC
[CentOS] Error trying to mount NFS volume from kickstart in CentOS 5
I'll follow up my original post with some more details (no solution yet, though). The problem is that when I try to do an NFS mount during the post section of the kickstart, I get the following error: mount.nfs: Input/output error I modified my kickstart script to not shut down, and when the install completed, I fit Ctrl-Alt-F2 to get to the console. I typed the exact same mount command and it worked. Then I did a "chroot /mnt/ sysimage" and tried the mount command again. This time it failed with the same error and it takes almost 2 minutes for it to time out. Here are the last few lines from an strace of the mount: 11:07:07.320919 lstat64("/etc/mtab", {st_mode=S_IFREG|0644, st_size=24, ...}) = 0 11:07:07.321019 stat64("centosmirror:/local/www/html", 0xbf81ead0) = -1 ENOENT (No such file or directory) 11:07:07.321093 stat64("/sbin/mount.nfs", {st_mode=S_IFREG|S_ISUID| 0755, st_size=55012, ...}) = 0 11:07:07.321195 clone(child_stack=0, flags=CLONE_CHILD_CLEARTID| CLONE_CHILD_SETTID|SIGCHLD, child_tidptr=0xb7ff1928) = 4981 11:07:07.323011 wait4(-1, [{WIFEXITED(s) && WEXITSTATUS(s) == 32}], 0, NULL) = 4981 11:08:52.343024 --- SIGCHLD (Child exited) @ 0 (0) --- 11:08:52.343135 exit_group(32) = ? Have there been some changes to the mount command in CentOS 5 that are causing this problem? Anyone else successfully mounted an NFS share in the %post section of a kickstart script? Alfred