Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer

Help with fstab

by Dorficus (Initiate)
on Jan 19, 2012 at 12:15 UTC ( #948768=perlquestion: print w/ replies, xml ) Need Help??
Dorficus has asked for the wisdom of the Perl Monks concerning the following question:

Hi, I have an issue with how I should extract information from my fstab and display it for the user of my script so the user can make reasonable decisions without taking a shot in the dark

The script copies a disk and transfers it to another disk, but if the disk size differs this won't work, so you have to change the partition size of the target disk

As mentioned, I want to provide the user with information about the partitions of the original disk so that they know which disk is the boot partition, now can anyone tell me how I get this information from the fstab?

I am very thankful for any help provided, and if I could solve this problem it'd be great!

Comment on Help with fstab
Re: Help with fstab
by Anonymous Monk on Jan 19, 2012 at 12:20 UTC

      Thanks for the links but I'm new with perl so I have couple of more questions

      new ( node => $node_obj, name => 'fstab' ) ;
      read ( io_handle => ... )
      write ( io_handle => ... )

      This is the code he provides me with, but what should I write instead of "node", "name" and both "..." Any ideas? Sorry for my poor presentation of questions, but my knowledge is poor :(

        What are you talking about? Link please

Re: Help with fstab
by salva (Abbot) on Jan 19, 2012 at 13:00 UTC
    fstab does not contain information about which one is the boot partition.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://948768]
Approved by Corion
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (5)
As of 2015-01-31 22:25 GMT
Find Nodes?
    Voting Booth?

    My top resolution in 2015 is:

    Results (261 votes), past polls