bug-parted
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

libparted and the correct device path


From: B.Hakvoort
Subject: libparted and the correct device path
Date: Sun, 04 Jul 2004 14:29:24 +0200

Hey,

I'm sure this has been up at least a dozen of times, but i couldnt find
anything in the archives ( except for russian(?) threads :^) )

Anyway, i'm hacking on the c++ wrapper for libparted
(http://www.nongnu.org/libpartedpp/) and i've stumbled upon some
problems. When libparted checks if a partition is busy it looks into
/proc/mounts,/proc/swaps and /etc/mtab, if the path of the partition is
found somewhere, ped_partition_is_busy() returns true, otherwise false.

And here's the problem: libparted asks the device for it's path, which
usually ( since kernel 2.5 IIRC ) is something like :
ide/host0/bus0/target0/lun0/disc  while most users/distros refer to
their devices as /dev/hda ( which is a symlink to the real path of
course )
thus functions which depend upon the path will most likely fail.

I'm sure this is a known matter and i'm curious about any solutions. I
have some ideas to solve this, but first i like to know if the problem
is still there. 

And maybe it's just me, doing something terribly wrong ;-)

Best regards,

Bart




-- 
www.titanium-it.nl --- Open Minded Open Source
www.heavenisopen.com <-----Another Source





reply via email to

[Prev in Thread] Current Thread [Next in Thread]