Setting a drive's volume label

B

Bob Greschke

....the name for a drive (hard or removable) that shows up when, for example,
a USB flash drive is recognized by the system. I don't know if this shows
up somewhere in Linux.

Can this be set from Python? I guess it would be some MFC call in Windows
(I don't know anything about doing that), and some ??? call in Linux? Could
use both.

Thanks!

Bob
 
B

Bob Greschke

Looks like the "label" system command will do it in Windows. That's good
enough for this exercise. So, in Linux...???
 
R

Reinhold Birkenfeld

Bob said:
Looks like the "label" system command will do it in Windows. That's good
enough for this exercise. So, in Linux...???

"mlabel" in the "mtools" package will do what you need. "mkfs.vfat" can also
be given a volume label, but it will not allow you to set the label without
creating a new filesystem :)

Reinhold
 
B

Bob Greschke

Reinhold Birkenfeld said:
"mlabel" in the "mtools" package will do what you need. "mkfs.vfat" can
also
be given a volume label, but it will not allow you to set the label
without
creating a new filesystem :)

Reinhold

Perfect! (Never heard of them :) Thanks!

Bob
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,482
Members
44,901
Latest member
Noble71S45

Latest Threads

Top