Bug #4279
HP-UX Remount Error
| Status: | Closed | Start date: | 07/18/2010 | |
|---|---|---|---|---|
| Priority: | Normal | Due date: | ||
| Assignee: | - | % Done: | 0% |
|
| Category: | HP-UX | |||
| Target version: | 2.6.3 | |||
| Affected Puppet version: | 0.25.5 | Branch: | MarkusQ:tickets/2.6.x/4279 | |
| Keywords: | ||||
| Votes: | 0 |
Description
The following error shows up in my hp-ux syslog:
Jul 17 22:12:32 SVR104244 puppetd[24639]: (//log::client/Mount[/logs]/ensure) change from present to mounted failed: Execution of '/sbin/mount -o defaults /logs' returned 1: mount: log.foo.net:/srv/cast_logs is already mounted on /logs
Which it is already mounted, so the message is right, just not sure why it’s trying to mount it again? The same module is working fine on my RHEL boxes. I’m trying to online some HP-UX systems into puppet, and so far this is the only thing that has caused me trouble. The initial mount and fstab modification worked just fine. I even tried adding ‘remount’ to the ‘options’, and it worked! of course, it doesn’t work on boot, or if it’s not mounted. :) There is no functional problem here, but it of course shows up as an error on the report, which is not really acceptable.
class logs::client {
file { "/logs":
ensure => directory,
owner => "root",
group => "root",
mode => 0777,
}
mount { "/logs":
device => "logs.foo.net:/srv/cast_logs",
fstype => "nfs",
ensure => "mounted",
options => "defaults",
remounts => "true",
atboot => true,
require => File["/logs"],
}
}
History
Updated by James Turnbull almost 2 years ago
- Status changed from Unreviewed to Needs More Information
Hi – can you show me full output of a run with —trace —debug and appropriate data on your mounts? Thanks
Updated by Stefan Schulte almost 2 years ago
James Turnbull wrote:
Hi – can you show me full output of a run with —trace —debug and appropriate data on your mounts? Thanks
I have the same Problem (2.6.0) and I found out that it is a problem in puppet/provider/mount.rb
mount on HP-UX gives you:
/foo on server:/foo
but mount.rb searches for 'on /foo' (which matches on Linux) instead of '/foo on'. I could fix that by adding another case at the end of the file wich is a duplicate of the Solariscase:
mounts = mountcmd.split("\n").find do |line|
case platform
when "Darwin"
line =~ / on #{name} / or line =~ %r{ on /private/var/automount#{name}}
when "Solaris"
line =~ /^#{name} on /
+ when "HP-UX"
+ line =~ /^#{name} on /
else
line =~ / on #{name} /
end
end
end
Updated by Stefan Schulte over 1 year ago
- File 0001-Fix-for-4279-HP-UX-Remount-Error.patch added
Because this bug is still present in 2.6.2 and mount is a core component that just dont work on HP-UX I’m wondering if noone uses puppet on HP-UX. But I just wanted to add the patch in a proper format…
Updated by Markus Roberts over 1 year ago
- Status changed from Needs More Information to In Topic Branch Pending Review
- Branch set to MarkusQ:tickets/2.6.x/4279
Branch up implementing this solution (slightly modified, & with tests adjusted).
Updated by James Turnbull over 1 year ago
- Target version set to 2.6.3
Updated by Markus Roberts over 1 year ago
- Status changed from In Topic Branch Pending Review to Ready For Checkin
Updated by Markus Roberts over 1 year ago
- Status changed from Ready For Checkin to Closed
Added to 2.6.x as commit:866205624873d0a6ab17c03061e89d74a3a77019