LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   3 issues: Making swap, fixing partitions, changing ownership of mounted filesystem. (https://www.linuxquestions.org/questions/linux-newbie-8/3-issues-making-swap-fixing-partitions-changing-ownership-of-mounted-filesystem-139312/)

Dunedain 01-27-2004 03:11 PM

3 issues: Making swap, fixing partitions, changing ownership of mounted filesystem.
 
I'm on RedHat 9.0, with a win2k (dualboot, if a dualboot is what I think it is.. dualboot = linux and win2k/other OS installed? or is it that it boots up both OS' at the same time?)


I'll start with the swap issue since all I really need is some advice on what program/commands I should use to make it. Basically all I need is a partition program, right?

Then to the "fixing partition" part:

I boot up my Linux and I notice that my fat32 partition contains errors. There is some difference between boot and something else(sorry I can't remember the exact wording). I figure I can run fdisk or cfdisk or even sfdisk to fix this, but the man fdisk really didn't help me and the man cfdisk seems non existant on my system. Could this error be occur because fat32 support still is alpha?

I really haven't dug into this seeing as I'm more concerned about my internet issue... But I've already asked about that on the Network forum.

Changing ownership of a mounted filesystem:

So I've been trying to chown my vfat filesystem, this is where most of my pleasure stuff is allocated so I want to have as much freedom as possible when moving around in there. So far I've only managed to change the ownership of the "/mnt/storage"(mountpoint), and I had to umount the filesystem to do that. Needless to say nothing below that catalog in the tree had it's ownership changed. I have an idea on using the chown on /dev/hda5(which is the vfat partition), but I want everything in the tree to be changed to my(read: kab) ownership.

my command would be something like this(I think..) chown -R --from root:root kab:kab /dev/hda5(or /mnt/storage).

Or are there other commands I should use, like chmod? Hope this isn't too much. Feel free to answer with pin pointers or just plain suggestion. Only do it in a understandable way.

Thanks ^_^

EDIT: Stupid notepad...

zokik 01-27-2004 03:45 PM

Quote:

dualboot = linux and win2k/other OS installed?
Right. Or any 2 OSs installed.

SWAP:
mkswap, but the easiest way to manage partitions is with parted and qtparted as frontend to parted. You usually can't check or repair mounted partitions, but you can always boot a distro like knoppix or mepis if you can't umount, e.g. if you want to do something with the / partition.
FAT PARTITIONS:
dosfsck, fsck.msdos, or fsck. fsck is for any type of partition (actually any filesystem). AFAIK fdisk is usually just for creating/deleting/... partitions.
I wouldn't say fat support is alpha. ntfs write support with 2.4.* kernels is alpha

You can't change permissions nor ownership of files on fat, because fat filesystem doesn't support them. However, you can set permissions and ownership for all files on fat or on ntfs when you mount that filesystem. For example: to set permissions to r-xr-xr-x use these options or put them in /etc/fstab:
umask=0222,noexec
You need x permissions to enter directories, but you don't want to allow really executing binaries on fat if you don't have any linux programs on fat. Note that with umask you tell what permissions files WON'T have - without 222, i.e. without write for everyone. I forgot what's the deal with the leading zero.
For ownership use uid= and gid= , do a "man mount" for details, but IIRC you just use for example:
uid=some_user,gid=some_group

Dunedain 01-27-2004 03:52 PM

So that's what those gid='s and uid='s were there for..

And the reason I say fat32 support is alpha is beacuse I get that as a warning message when booting up. I think it's just something that is outdated. I'll check it in the morning.

Thanks for your help! Hopefully this is the last time I'll come wailing after just a little research of my own. Perhaps I'm a little to lazy to run Linux? </retorical question>


All times are GMT -5. The time now is 04:35 AM.