﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	severity	resolution	keywords	cc
288	mindi --makemountlist fails on /etc/fstab with multiple (identical device) entries	bwiberg	Bruno Cornec	"Multiple entries in /etc/fstab, where the device name (e.g. //server/share) is identical, although the mount points for the two mounts differ, yield an error when calculating the partition size in SizeOfPartition() of mindi.

Multiple entries may occur e.g. for CIFS if mounting the same share as different users on different mount points.

Attaching suggested patch which assumes that all mounts of a device share a common amount of free space (however, is this true in the case of quotas on shares?).

{{{
sprinkle:~# /usr/sbin/mondoarchive -O -9 -d ""/mnt/backup/bwiberg/bwiberg/mondorescue"" -E ""/home /mnt /mnt/backup/bwiberg/bwiberg/mondorescue"" -F -i -N -p ""sprinkle"" -s 4700m -S ""/tmp"" -T ""/tmp"" -V
Initializing...
See /var/log/mondoarchive.log for details of backup run.
Checking sanity of your Linux distribution
mindi --makemountlist //mondo.tmp.8b5Lv8/mountlist.txt.test failed for some reas
Please run that command by hand and examine /var/log/mindi.log
for more information. Perhaps your /etc/fstab file is insane.
Perhaps Mindi's MakeMountlist() subroutine has a bug. We'll see.
Failed.
Fatal error... Pre-param initialization phase failed. Please review the error messages above, make the specified changes, then try again. Exiting...
---FATALERROR--- Pre-param initialization phase failed. Please review the error messages above, make the specified changes, then try again. Exiting...
If you require technical support, please contact the mailing list.
See http://www.mondorescue.org for details.
The list's members can help you, if you attach that file to your e-mail.
Log file: /var/log/mondoarchive.log
FYI, I have gzipped the log and saved it to /var/cache/mondo/MA.log.gz.
Mondo has aborted.
Execution run ended; result=254
Type 'less /var/log/mondoarchive.log' to see the output log
}}}
So, running mindi manually:
{{{
sprinkle:~# mindi --makemountlist /tmp/a.txt
Your mountlist will look like this:
Analyzing LVM...
        DEVICE          MOUNTPOINT      FORMAT          SIZE (MB)       LABEL/UUID
        /dev/sda1       /               ext3              15390
        //192.168.1.2/bwib /home/bwib      cifs             472785
        //192.168.1.2/bwiberg /home/bwiberg   cifs             472785
/usr/sbin/mindi: line 1199: 484131936 484131936/1024: syntaxfel i uttryck (error token is ""484131936/1024"")
}}}
(Translation: ""syntax error in expression"")
{{{
Mindi Linux mini-distro generator v2.0.4-r2045
Latest Mindi is available from http://www.mondorescue.org
BusyBox sources are available from http://www.busybox.net
------------------------------------------------------------------------------
Mindi-BusyBox v1.7.3-r2045 (2008-10-13 00:08:43 CEST) multi-call binary
Do you want to use your own kernel to build the boot disk ([y]/n) ?^CFATAL ERROR. Program is terminating in response to signal received from OS/user
Please e-mail a copy of /var/log/mindi.log to the mailing list.
See http://www.mondorescue.org for more information.
WE CANNOT HELP unless you enclose that file.

sprinkle:~# cat /tmp/a.txt
/dev/sda1 / ext3 15759733
//192.168.1.2/bwib /home/bwib cifs 484131936
//192.168.1.2/bwiberg /home/bwiberg cifs 484131936
}}}
(Note how only the two first CIFS entries appear above!)
{{{
sprinkle:~# apt-show-versions | grep mondo
^[[Amondo/unknown uptodate 2.2.7
sprinkle:~# apt-show-versions | grep mindi
mindi/unknown uptodate 2.0.4
mindi-busybox/unknown uptodate 1.7.3-1

# /etc/fstab: static file system information.
#
# <file system> <mount point>   <type>  <options>       <dump>  <pass>
proc            /proc           proc    defaults        0       0
/dev/sda1       /               ext3    errors=remount-ro 0       1
//192.168.1.2/bwib      /home/bwib              cifs    iocharset=utf8,nobrl,uid=bwib,gid=bwib,file_mode=0660,dir_mode=0770,username=bwib,password=SECRET             0       0
//192.168.1.2/bwiberg   /home/bwiberg           cifs    iocharset=utf8,nobrl,uid=bwiberg,gid=bwiberg,file_mode=0660,dir_mode=0770,username=bwiberg,password=SECRET    0       0
//192.168.1.2/backup    /mnt/backup/bwib        cifs    iocharset=utf8,nobrl,uid=bwib,gid=bwib,file_mode=0600,dir_mode=0700,username=bwib,password=SECRET             0       0
//192.168.1.2/backup    /mnt/backup/bwiberg     cifs    iocharset=utf8,nobrl,uid=bwiberg,gid=bwiberg,file_mode=0600,dir_mode=0700,username=bwiberg,password=SECRET    0       0
//192.168.1.2/media     /mnt/media              cifs    iocharset=utf8,nobrl,uid=bwiberg,gid=bwiberg,file_mode=0664,dir_mode=0775,username=bwiberg,password=SECRET    0       0

sprinkle:~# df -k
Filsystem             1K-block    Använt Tillgängl Anv% Monterat på
/dev/sda1             15512328   1454092  13270252  10% /
tmpfs                   513760         0    513760   0% /lib/init/rw
udev                     10240        72     10168   1% /dev
tmpfs                   513760         0    513760   0% /dev/shm
//192.168.1.2/bwib   484131936 239106592 245025344  50% /home/bwib
//192.168.1.2/bwiberg
                     484131936 239106592 245025344  50% /home/bwiberg
//192.168.1.2/backup 484131936 239106592 245025344  50% /mnt/backup/bwib
//192.168.1.2/media  484131936 239106592 245025344  50% /mnt/media
//192.168.1.2/backup 484131936 239106592 245025344  50% /mnt/backup/bwiberg
sprinkle:~#
}}}"	defect	closed	normal	2.2.9	mindi	2.2.7	normal	fixed		
