Extend zfs storage filesystem

Hello,

Need to ask the question regarding extending the zfs storage file system.

currently after using the command, df -kh

u01-data-pool/data  600G  552  48G 93% /data

/data are only 48 gb remaining and it has occupied 93% for total storage.

zpool u01-data-pool has more then 200 gb space are available, how we can

increase the size of u01-data-poo/data

We used the below command to increase the size of the file system, it work but not showing the complete space.

zfs set quota=700g u01-data-pool/data 

after used above command, the file sytem /data are

u01-data-pool/data 700G 552G 82G 88% /data

Kindly explain us why the available space are not showing 148gb instead of 82 gb.

Please advice us.

Regards,
khan

Can you provide out of :

zfs list -t all -o space -r u01-data-pool

Regards
Peasant.

# zfs list -t all -o space -r u01-data-pool

NAME                AVAIL   USED  USEDSNAP  USEDDS  USEDREFRESERV  USEDCHILD
u01-data-pool       82.4G   752G         0     31K              0       752G
u01-data-pool/data  82.4G   552G         0    552G              0          0
u01-data-pool/u01    190G  10.0G         0   10.0G              0          0

How big is the entire zpool ?

zpool list u01-data-pool

Also examine the output the following, looking for quota, refquota, reservation and refreservation set on each filesystem.

zfs get refquota,quota,refreservation,reservation u01-data-pool
zfs get refquota,quota,refreservation,reservation u01-data-pool/data
zfs get refquota,quota,refreservation,reservation u01-data-pool/u01

Hope that will shed a light to the problem.
Regards
Peasant.

# zpool list u01-data-pool

NAME SIZE ALLOC FREE CAP HEALTH ALTROOT
u01-data-pool 848G 562G 286G 66% ONLINE -

# zfs get refquota,quota,refreservation,reservation u01-data-pool

NAME PROPERTY VALUE SOURCE
u01-data-pool refquota none default
u01-data-pool quota none default
u01-data-pool refreservation none default
u01-data-pool reservation none default

# zfs get refquota,quota,refreservation,reservation u01-data-pool/data
NAME PROPERTY VALUE SOURCE
u01-data-pool/data refquota none default
u01-data-pool/data quota 700G local
u01-data-pool/data refreservation none default
u01-data-pool/data reservation none local

# zfs get refquota,quota,refreservation,reservation u01-data-pool/u01

 NAME                   PROPERTY          VALUE      SOURCE

u01-data-pool/u01 refquota none default
u01-data-pool/u01 quota 200G local
u01-data-pool/u01 refreservation none default
u01-data-pool/u01 reservation 200G local

Please use code tags, according the the forum rules.

The file system u01-data-pool/u01 has a reservation property set to 200 GB.

Property reservation will do just that, reserve 200 GB for the specified zfs filesystem - guaranteeing 200 GB.
It will show as used space as soon as it's set with zfs set command.

Since the mentioned file system with reservation property has only 10 gb used, lowering that property will effectively increase the usable space for other filesystems under the zpool.

As for the reasons for such setup, you should check with administrator or one who made it.

Hope that helps
Regards
Peasant.

Dear peasant,

Thanks for your reply, I have a target to increased the size of u01-data-pool/data file system, because all oracle database files are reside there.

For u01-data-pool/u01 have oracle binary files , so no issues for this file system.

Need a command to proper extend the size of u01-data-pool/data pool.

Hope you understand my point.

Regards,

Both filesystems are under the same zpool.

So removing or lowering the reservation on u01 filesystem will have that effect.
You will now see additional 200 GB of space, since you increased the quota on /data earlier.

Regards
Peasant.

Hello peasant,

Thanks brother for your reply, I need your support to reduce the reservation size of /u01 and increase the free space size of /data file system.

I have a one confusion, kindly clarify the confusion, last time I used the below zfs set quota command to increased the size of u01-data-pool/data

zfs set quota = 700g u01-data-pool/data

after above command the file system of /data are 700 gb from 600 gb and the free available space was 48 gb after that it is 82 gb.

So why the available space are not 148 gb , why it has increased 34 gb more to come 82 gb.

kindly advice us.

Regards,

Reading about zfs reservation and quotas could be a start of understanding those.

In your case a simple :

zfs set reservation=100GB u01-data-pool/u01

Will show 100 GB of additional space available for other datasets in zpool.

A zfs quota is effectively a soft limit to a dataset (filesystem).
It does not change the USED of entire zpool.

A zfs reservation is a hard limit to a dataset (filesystem).
It does change USED of entire zpool.

Hope that clear things out.
Regards
Peasant.

Hello peasant,

Thanks for your guide & I am very glad to inform that after used the below command.

zfs set reservation=100GB u01-data-pool/u01

the /data file system are extended and the free space are 141 gb, before it was 75 gb.

u01-data-pool/data 700G 559G 141G 80% /data

Again appreciate & thanks.

Now the same scenario has our production environment & we have not a more space

to store the db data.

$ zpool list prod-db-pool

NAME SIZE ALLOC FREE CAP HEALTH ALTROOT
prod-db-pool 848G 629G 219G 74% ONLINE -

after df -kh , the space for /data & /u01 are below, both are in same pool.

prod-db-pool/data 600G 576G 24G 97% /data

prod-db-pool/u01 200G 53G 147G 27% /u01

Now our important file system is /data and it has only 24GB remaining, kindly guide us

how to extend the free space of /data file system.

Regards,

I think i've done enough to help and guide you.
Using the knowledge you received from the posts on this subject, you should be able to reach similar conclusions/solutions independently.

This forum is meant to guide you, not to offer done solutions for every possible variation on given subject.

We are not your unpaid programming or engineering staff.

Regards
Peasant.

2 Likes

Hello Peasant,

Thanks for your reply & again appreciate for your guide & support.

I know that you are helping me to understand the actual issue, how to extend the file system as per our scenario.

Just need one more favour to fix the last issue , after that i will close the thread.

Again i have really appreciate your effort to help & solve the issue.

Regards,

---------- Post updated at 04:30 PM ---------- Previous update was at 08:59 AM ----------

Hello Peasant,

I am waiting for your feedback, kindly guide me to the last issue that i have faced.

Highly appreciated for your guide & support.

Regards,

@Shahzad53, I'm afraid you missed the point. You give the impression not to have make any effort to try to understand what was explained. You didn't even follow the multiple requests to use code tags in your postings.

I would suggest you to read again and understand what was taught, if unclear read the various resources about ZFS administration you'll find on the net, e.g. Oracle Solaris 10 ZFS Administration Guide or Managing ZFS File Systems in Oracle Solaris 11.4, build a test zpool and experiment with various settings.

1 Like

Hi,

Thanks for your guide & help and understand the whole scenario.

Regards,