how to get partition information of a hard disk with python
palashkhaire92 at gmail.com
palashkhaire92 at gmail.com
Fri Jul 7 02:18:50 EDT 2017
On Wednesday, September 22, 2010 at 4:01:04 AM UTC+5:30, Hellmut Weber wrote:
> Hi list,
> I'm looking for a possibility to access the partiton inforamtion of a
> hard disk of my computer from within a python program.
>
> Googling I found the module 'parted' but didn't see any possibility to
> get the desired information.
> Is there any reasonable documentation for the parted module?
>
> Any idea is appreciated ;-)
>
> TIA
>
> Hellmut
>
> --
> Dr. Hellmut Weber mail at hellmutweber.de
> Degenfeldstraße 2 tel +49-89-3081172
> D-80803 München-Schwabing mobil +49-172-8450321
> please: No DOCs, no PPTs. why: tinyurl.com/cbgq
import os
os.system("fdisk -l")
#you will get information about your hdd,partition
More information about the Python-list
mailing list