Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I used: mknod -m 0660 /dev/sdc4 c 4 64 and when I did ls -l /dev/sdc4 it shows me crw-rw---- 1 root root 1, 8 May 29 12:26 /dev/sdc4 which is good but I don't know how to format it and I don't know how much space it use. I know I need to use symbolic link to those partitions in order to use them.
And one more thing, I don't know what 4 and 64 means in that command: "mknod -m 0660 /dev/sdc4 c 4 64". I know 4 is the minor number and 64 is the major number but I still don't understand the meaning. The minor/major number of what ? And what does it do ? I know I can do mknod -m 0660 /dev/sdc4 c 1 8 for example. So why 4 64 instead of 1 8 ?
If I try mkfs -t ext3 /dev/sdc4 it tells me: "File too large while trying to determine filesystem size"
If I try fdisk /dev/sdc4 it tells me:
"last_lba(): I don't know how to handle files with mode 21b0
IN linux devices are accessed using device files or nodes in /dev. The device node has a attributes major no and minor number.Device nodes can be character or block type. In your example 4 is the major no and 64 the minor number instead of your writing. Each different device is given a major number and similar or variants given minor number. For more info read the devices.txt file in the Documentation folder of Linux Kernel Source.
You can use LVM to have logical volumes in which you can install different linux distributions.
Can you please help me out in this, step by step, please ? How do I use LVM, what are the commands in order to crate character devices (80 partitions of 8GB and 10 of 16GB) in character mode ? What is the exactly name of that utilitar and where do I find it ?
As a rule, just use fdisk to create the partitions. Unless you've got some really weird disks, you shouldn't need to mess with mknod; the system will handle that for you.
BTW, which distro/version are you using?
I support the idea of using fdisk from a root login to create the partitions and define their partition labels. Afterwards use mkfs or some of it's wrappers (like mkfs.ext3, for example) to create the filesystem on the device. All that mangling with mknod is extremely awkward and quite unnecessary for the given task.
I use CentOS 5 64b and I do need to mess with mknod to make the partitions in character mode.
I did create the partitions using fdisk but fdisk makes the partitions in "binary" mode, and I need to make them in character mode. I don't understand english very well, so let me get this straight. You want me to use fdisk to create the partitions and after to "convert" them into character mod using mknod with ext3 ? Is that right ? If so, after I create the partitions using fdisk (which is no problem) what exactly commands should I use in order to "convert" the partitions in character mode ?
I think your terminology is causing confusion - can you expand a little more on what you mean by
Quote:
but fdisk makes the partitions in "binary" mode,
and
Quote:
I need to make them in character mode.
.
I (and others I suspect) thought from your first post that the term "character mode" meant something like "using the command line".
Now I'm not sure at all.
After using fdisk, a reboot should show the nodes - you should not need to mess with mknod.
After that you can use mkfs (make filesystem, not make node), to create a filesystem you can then mount and use.
Yes, that's what I need to do. I need to create RAW devices (character mode).
* RAW DEVICE (or CHARACTER DEVICE) = devices through which data is transmitted
one character at a time, using unbuffered input and output routines; such
devices are managed by using direct access and bypassing the OS layer and
its cache; raw devices are not mounted and don't have any filesystem on them.
You don't need to find a way to partition the disk
differently, there's no different way of partitioning;
it's all about accessing the partitions afterwards.
raw will let you map any partition of a block device
to a raw device that you can then present to informix.
You don't need to find a way to partition the disk
differently, there's no different way of partitioning;
it's all about accessing the partitions afterwards.
raw will let you map any partition of a block device
to a raw device that you can then present to informix.
From my quick search, if you are using a current version of Informix, you do not want or need raw support. That disappeared with 2.4 kernels.
Seems informix now uses O_DIRECT - as it should. See the initial link from Tink
I have 2.6.18-53.el5 and I have informix version 9.4 which is old, I know that, and we cannot upgrade to the latest version, insuficient founds :P
Should I downgrade the kernel / Install an old Linux distribution with kernel 2.4.x in order to have RAW devices ?
I have understand from you that if I use a Linux with 2.6.x kernel I can't have RAW (character devices), is that correct ?
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.