Solved I have an EXT4 partition .....Can this cause any complications later ? Should I format it to UFS ?

I have one SSD where FreeBSD is installed. I also have a spinning HDD where I keep my data. This spinning HDD is EXT4 since I was using Linux before. FreeBSD's support for EXT4 is very nice. I don't feel I am using a non native filesystem. Everything is working smoothly.

My question is if I keep this EXT4 partition as it is can this cause any complications later on ?
If the answer is yes then which filesystem should I choose ? UFS ?
 
If that disk is meant to be used with FreeBSD only, it's a good idea to switch to a native filesystem. Other filesystems may work fine but will always be less tested and more prone to bugs.

As for UFS vs ZFS, it's up to you, there are lots of posts about it here, personally I'd use ZFS in any case, especially for data storage.
 
If that disk is meant to be used with FreeBSD only, it's a good idea to switch to a native filesystem. Other filesystems may work fine but will always be less tested and more prone to bugs.
I agree.

As for UFS vs ZFS, it's up to you, there are lots of posts about it here, personally I'd use ZFS in any case, especially for data storage.
Depends on your amount of RAM. If it's a potato PC, you should use UFS2 rather than ZFS.
 
EXT4 is not a "native" FS so if this drive is used only for FreeBSD you should probably use UFS.

Regarding ZFS, I never use it unless there is at least a mirror set up.
 
bsduck eternal_noob gkontos
My FreeBSD install is ZFS. I have only 4GB of Ram but my desktop is quite responsive. I dont do a lot of multitasking. Besides Firefox with 2-3 tabs I sometimes run Smplayer. I guess I will use UFS.

I have no idea how to fomat a partition under FreeBSD. I am familiar with Gparted.

Time to visit startpage.com.
 
For the records:
 
I am feeling a bit nervous. What if I format the wrong partition by mistake ? Can you please get me started about how to format this partition to UFS2 ?
 
Dear john_rambo,
I would use ZFS. If you are not used to prepare a disk you could do first tests with a USB stick or a device created by mdconfig(8). In case of a desktop there might be the option to use a different spinning disk for experiments. To be safe you can additionally detach the Ext4 disk during the tests. If things are running right now with Ext4 it should be good not to hurry but to build up knowlegde and confidence.
 
I umounted the partition then did

newfs -U /dev/ada0p1

After a reboot its still reporting as linux-dta

Code:
> gpart show ada0
=>       34  312581741  ada0  GPT  (149G)
         34       2014        - free -  (1.0M)
       2048  312578048     1  linux-data  (149G)
  312580096       1679        - free -  (840K)
 
Or in your case you could, gpart delete -i 1 /dev/ada0 and then gpart add -t freebsd-ufs /dev/ada0

Then newfs -U /dev/ada0p1
 
Did the following

gpart destroy -F /dev/ada0

newfs -O 2 -U -j -L spinning ada0

Then did a full reboot

I am able to mount the partition.

Code:
> mount
zroot/ROOT/default on / (zfs, local, nfsv4acls)
devfs on /dev (devfs)
procfs on /proc (procfs, local)
linprocfs on /compat/linux/proc (linprocfs, local)
tmpfs on /compat/linux/dev/shm (tmpfs, local)
linsysfs on /compat/linux/sys (linsysfs, local)
fdescfs on /dev/fd (fdescfs)
zroot/tmp on /tmp (zfs, local, nosuid, nfsv4acls)
zroot/var/audit on /var/audit (zfs, local, noexec, nosuid, nfsv4acls)
zroot/usr/home on /usr/home (zfs, local, nfsv4acls)
zroot/var/crash on /var/crash (zfs, local, noexec, nosuid, nfsv4acls)
zroot/usr/ports on /usr/ports (zfs, local, nosuid, nfsv4acls)
zroot/usr/src on /usr/src (zfs, local, nfsv4acls)
zroot/var/mail on /var/mail (zfs, local, nfsv4acls)
zroot/var/tmp on /var/tmp (zfs, local, nosuid, nfsv4acls)
/dev/ada0 on /media/ada0 (ufs, local, noatime, soft-updates, journaled soft-updates)
devfs on /compat/linux/dev (devfs)
fdescfs on /compat/linux/dev/fd (fdescfs)
tmpfs on /compat/linux/dev/shm (tmpfs, local)

But gpart show strange output

Code:
> gpart show ada0
gpart: No such geom: ada0.

Note : After using gpart destroy -F /dev/ada0 the "p1" is gone.

Code:
/dev> ls ad*
ada0   ada1   ada1p1 ada1p2 ada1p3
 
Mostly it's best to use a partition scheme.
If you need to boot from it and only need maximum 4 partitions I would advice to use mbr scheme.
Otherwise create a gpt scheme.
 
Alain De Vos

Done !

Code:
~> gpart show ada0
=>       40  312581728  ada0  GPT  (149G)
         40  312581728     1  freebsd-ufs  (149G)

But the partition is read only. The chown command is also not working

Code:
> sudo chown -R home:home /media/ada0p1/
chown: /media/ada0p1/.sujournal: Operation not permitted

How do I fix this ?
 
.sujournal belongs to root:wheel. No need to change it.
You could :
Code:
sudo chown -f -R home:home /media/ada0p1/
There is no such thing as a read-only ufs partition.
But you can mount a ufs partition in read-write mode or read-only mode.

The following output can be interesting :
Code:
mount | grep /media/ada0p1
 
Alain De Vos
I am not sure what really happened but despite the chown command failed with "Operation not permitted" now I can write to this partition. I am at the moment restoring my data from by external USB drive.

[SOLVED] Thanks everyone.
 
Back
Top