Solved How can I group two or more hard drives to create a single large volume ?

Nope. I love FreeBSD :D
Well... try this:

# kldload /boot/kernel/geom_linux_lvm.ko
# cd /usr/ports/sysutils/fusefs-ext4fuse/
# make install clean
# mkdir /mnt/blah
# ext4fuse /dev/linux_lvm/volumegroup-logicalvolume /mnt/blah
# cp -r /mnt/blah/home/username/stuff /home/username/stuff
# chown -R username /home/username/stuff

I would not bet though too much on FreeBSD supporting more advanved LVM stuff anyway. It's more like a crutch than a solution. The solution is ZFS or GEOM.
 
what about if I reformat the Openbsd and the Dragonflybsd ssd disks using ZFS ? my main FreeBSD installation which run on a UFS2 fs can read and write on those disks ? Can you provide a tutorial where I can learn how can I group two ssd disks of the same size using ZFS ?
 
Adding any disk of any size to a zpool is a piece of cake.
Just create a GPT partition table, a freebsd-zfs partition XXX and do,
Code:
zpool add mypool XXX.
Done.
 
I want to keep intact the UFS2 partition where I have installed my main freebsd OS. But I can reformat the other two ssd disks with zfs. It will work ? I'm a newbie,can u give me a tutorial that explains the whole scenario ?
 
Let's say the two ssd disks are /dev/ada1 and /dev/ada2.
You just have to do something like:
Code:
gpart create -s GPT ada1
gpart create -s GPT ada2
gpart add -l ssd1 -t freebsd-zfs ada1
gpart add -l ssd2 -t freebsd-zfs ada2
zpool create myzpool /dev/gpt/ssd1 /dev/gpt/ssd2
zfs create myzpool/myzfs
 
I recommend creating a couple of md devices from a couple of files and experimenting with gconcat etc. Even if you make a mistake, no harm done. You can start again. Something like (as root)
for a in 0 1; do truncate -s 4G file$a; mdconfig -t vnode - f file$a; done

Now you have two devices /dev/md[01] to play with! You can even do hexdump on them to see what changes. Choose a smaller size for that though. Second, experiment as you read the man page. Try out various sub commands. Quickly making sense of a manpage is a skill that will come in handy over and over again. You won’t find tutorials for everything, nor are most tutorials all that good.
 
I'm going to install FreeBSD on another ssd disk (called /dev/sda ; 460 GB large) using the ZFS fs. As I said,I have another ssd disk of the same size,called /dev/sdb. If I want that the new FreeBSD installation will occupy the space of the 2 disks,which option should I choose below ?

8.png
 
Yes. Just be carefull not to "destroy" by accident the wrong device/disk.
After install completed and reboot into freebsd you can simply add the other disk to the zpool.
I.e. "zpool add mypool seconddiskdevice"
 
If you want the equivalent of RAID0, use stripe. Your pool will be dead if either of the disks die, but you get extra space.

It's generally a better idea to have some sort of redundancy (eg, mirror), but if you are diligent on backups or don't care about your data, you can make the choice to stripe them instead.
 
I've removed OpenBSD and I will remove DragonFlyBSD later,because I want to focus myself only on FreeBSD and that's enough. Instead of OpenBSD I've reinstalled FreeBSD on the disk ada0 using the ZFS fs. The disk has been partitioned like so :

Code:
=>       40  976773088  ada0  GPT  (466G)

         40     532480     1  efi  (260M)
     532520       1024     2  freebsd-boot  (512K)
     533544        984        - free -  (492K)
     534528    4194304     3  freebsd-swap  (2.0G)
    4728832  972044288     4  freebsd-zfs  (464G)
976773120 8 - free - (4.0K)

For sure now I want to mount the partition /dev/ada0p4 that's the root of the new FreeBSD installation. I'm reading here how to do that :


he says to do :

Code:
mario@marietto:/usr/home/marietto # zpool import

pool: zroot
id: 17047367030737245538
state: ONLINE
action: The pool can be imported using its name or numeric identifier.
config:
zroot       ONLINE
ada0p4    ONLINE


mario@marietto:/usr/home/marietto # zpool import -fR /mnt/zroot zroot

mario@marietto:/usr/home/marietto # cd /mnt/zroot

mario@marietto:/mnt/zroot # ls
tmp usr var zroot

mario@marietto:/mnt # zpool import -fR /mnt/ada0p4 ada0p4
cannot import 'ada0p4': no such pool available

something is wrong here. I don't see all the common files of FreeBSD. I need to find the file fstab because I need to remove a parameter that's wrong inside it. Infact I put inside of it something like this :

/dev/ada0p4 / zfs rw 1 1

and I should remove this line or it will not boot. How and where I can find it ?
 
Please, read the handbook:

ZFS does not normally use fstab nor can you mount it like you are trying. You don't see all the OS files because the OS dataset is marked as canmount=noauto by default.
 
Don't tell me to read the handbook. Give me a less detailed reading. The handbook is too much filled of informations. I never go there because I don't want to be overhelmed by informations. I want to learn only some concepts at a time. I do not find it at all respectful to tell someone to read such a considerable amount of information. It is also a trivial advice. Ask yourself why people ask the questions then. If they find easy and useful to read the manual they would it and then there would be no more forums. What would you say if you are the one who asks me a psychology question and then I tell you to read a 500-page tome ? Don't do what you don't want people do to you. Anyway on "your" handbook it does not talk about the parameter canmount at all.

Maybe this command is the right one ?

zpool import -R /mnt/zroot zroot

I've read it here :
 
With ZFS:

… I want to mount the partition /dev/ada0p4 …

If you allowed the installer for FreeBSD to automatically perform the partitioning, then the required file systems will mount automatically when FreeBSD starts.

Hints:
  • a file system can be mounted
  • a partition can not be mounted
  • the partition was given to a ZFS pool
  • the pool includes multiple file systems.
It may help to think of a pool as a collection.
 
Don't tell me to read the handbook. Give me a less detailed reading. The handbook is too much filled of informations. I never go there because I don't want to be overhelmed by informations. I want to learn only some concepts at a time. I do not find it at all respectful to tell someone to read such a considerable amount of information. It is also a trivial advice. Ask yourself why people ask the questions then. If they find easy and useful to read the manual they would it and then there would be no more forums.
The reason why people don't read manuals are manyfold, the most important though are these:

1. there are different ways to learn stuff, and each individual has its own preference. For some reading works great, for others seeing it - so videos, for third repeating instructions, so mimicking the way somebody does. That's totally normal.
2. Most people nowadays are just lazy, and why reading a manual when asking questions somewhere leads much faster to the desired answer?
 
Don't tell me to read the handbook. Give me a less detailed reading.
Sorry, but no. That's not how this works. You clearly do not understand how computers and operating systems work, have not put in the effort to learn, and boast about how you do not want to learn. This isn't how this forum works.

You don't have to use the handbook, there are dozens of other resources for learning ZFS; the best alternative to the handbook for what's directly relevant to FreeBSD is zfsconcepts(7) and zpoolconcepts(7). It would be OK to ask for clarification after you read any of the abundant resources available and still have questions, but it is not OK to refuse to use the resources in the first place.
 
… canmount …

As an example, it's normal to find canmount off for the ZFS file system that has mountpoint /usr

Here, august is the pool that contains my installation of FreeBSD:

Code:
% zpool list
NAME        SIZE  ALLOC   FREE  CKPOINT  EXPANDSZ   FRAG    CAP  DEDUP    HEALTH  ALTROOT
Transcend   464G   214G   250G        -         -    28%    46%  1.00x    ONLINE  -
august      912G   655G   257G        -         -    34%    71%  1.00x    ONLINE  -
% zfs get canmount | grep off
august/tmp                                               canmount  off       received
august/usr                                               canmount  off       local
august/var                                               canmount  off       local
% zfs get canmount,mountpoint august/usr august/usr/home
NAME             PROPERTY    VALUE       SOURCE
august/usr       canmount    off         local
august/usr       mountpoint  /usr        local
august/usr/home  canmount    on          default
august/usr/home  mountpoint  /usr/home   inherited from august/usr
%

I must not run zfs mount august/usr. The installation of FreeBSD does not require this particular mount.

I chose canmount off for august/tmp because I prefer tmpfs(5), not ZFS, for my /tmp.



Conceptualziomario for your case, I should treat these pages as future points of reference, not paths to learning:
 
Don't tell me to read the handbook. Give me a less detailed reading. The handbook is too much filled of informations. I never go there because I don't want to be overhelmed by informations. I want to learn only some concepts at a time.
Then just read the chapter you are interested in. Even there it is fine just to read a few sections of a chapter that apply to a certain issue or topic.
 
The reason why people don't read manuals are manyfold, the most important though are these:

1. there are different ways to learn stuff, and each individual has its own preference. For some reading works great, for others seeing it - so videos, for third repeating instructions, so mimicking the way somebody does. That's totally normal.
2. Most people nowadays are just lazy, and why reading a manual when asking questions somewhere leads much faster to the desired answer?

I never said that I don't want to read the manual. I said that I want to read a more specific section of the argument that its strictly tied to the problem that I'm facing. I ask this because I haven't a solid knowledge of computer science as a background. If I had it,I would ask less questions. I'm not lazy for sure. I try to learn by doing. The idea is to enjoy while I try to solve a problem,without burn my head. I think that I'm not lazy. I'm always here and I've solved a lot of problems. With your precious help,ok,but also with my efforts. I can't be lazy even because this is an hobby for me. Usually hobbies are for things that we like. Maybe jobs or school lessons aren't :D
 
Sorry, but no. That's not how this works. You clearly do not understand how computers and operating systems work, have not put in the effort to learn, and boast about how you do not want to learn. This isn't how this forum works.

You don't have to use the handbook, there are dozens of other resources for learning ZFS; the best alternative to the handbook for what's directly relevant to FreeBSD is zfsconcepts(7) and zpoolconcepts(7). It would be OK to ask for clarification after you read any of the abundant resources available and still have questions, but it is not OK to refuse to use the resources in the first place.

I never said that I don't want to read the manual. I said that I want to read a more specific section of the argument that its strictly tied to the problem that I'm facing. You don't realize at all how much complicated can be something for someone who hasn't any background of it inside the brain. No,man,you like to win easily because you are not putting yourself inside the shows of someone else. Its easy for you to think that what you have already learnt is easy. And your suggestion to read the whole argument (I don't know how many pages are) is trivial and irritating. If u want to help give me a small amount of informations. This is an hobby for me. It's good as long as it remains so. If I should learn an huge amount of informations without to know a lot of other informations,it became a suffering. Luckily there are people able to give more specific suggestions. They have the gift of the synthesis and they are able to give advices that aren't neither too vague nor too specific. This is what I'm looking for.
 
Back
Top