xfs
[Top] [All Lists]

Re: Any better way to interact with xfs?

To: Ryan Lindsay <rlindsay@xxxxxxxxxxxxxx>
Subject: Re: Any better way to interact with xfs?
From: Amir Goldstein <amir73il@xxxxxxxxx>
Date: Thu, 28 Jul 2016 09:48:07 +0300
Cc: "xfs@xxxxxxxxxxx" <xfs@xxxxxxxxxxx>
Delivered-to: xfs@xxxxxxxxxxx
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=OCFqTvYaOe9WDQuQc8ycyt6BjXr/3cBkbJqKRbzntoo=; b=YpDxP429MU1G4AcmXovjv/Yy9l0iqKu81Z3oBNqSfxyt3V9vdg+XJUIF6kfMtPOpgF yw7k/2kBZWmMX6r7QliydXyoOwamPERJ6nozc2/efhLjmlqMrSSbNIFj60aeJykt/AB3 suVw/gavbCBAqLZax1tjjdFGFk9uECHGhNTF84P0pN169MkTkjSZEb6A1IYhHx+i0Ehj F6g7+w5nxPMo0BiwluV3up/MN0r8M+Ui2pPwTCn9fKA5OEsbXCPWzhHa0IXkev6YGOdi KC8MSrv8+unJZkj4LjoYRGNtMrT9q0DBjEKDaevvc+WtYPOhzgZ4DJpLDrSsXxQQ6MzF 7tew==
In-reply-to: <SYXPR01MB044863A851C967C37649BE3FF8000@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx>
References: <SYXPR01MB044863A851C967C37649BE3FF8000@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx>
Hi Ryan,

You could use the XFS_IOC_FSINUMBERS/XFS_IOC_FSBULKSTAT API to iterate
over all inodes in the fs.
not having to readdir and recourse the directory tree should safe you
some time (much less i/o).
Also, the interface can be used to make your conversion work parallel
by working on different inode ranges.
You can use xfsdump/xfsrestore code as reference.
Also, not sure if you are using user/group quotas - if you don't,
better make sure that quotas are turned off
to avoid all the accounting caused by your conversion process.

Amir.

On Thu, Jul 28, 2016 at 6:30 AM, Ryan Lindsay <rlindsay@xxxxxxxxxxxxxx> wrote:
> Hi
>
> I have a bit of a specific requirement.
>
> I have a server that currently has a 12T worth of data on it on an xfs
> formatted LV.
>
> currently the file permissions are set via an LDAP, however we are having to
> move to AD for out authentication mechanism. Which will change the value of
> the existing UID's and GID's
>
> Since XFS has a lot of mechanisms that allow things to happen in parallel. I
> was wondering if there was a way of interacting at the file system level to
> facilitate a change of UID's on files rather than having to just chown
> recursively down the file system. The faster I can update the permissions
> the better basically
>
>
> Ryan Lindsay | Research Infrastructure Lead
>
> Faculty of Science IT
> Room G09, Old Geology Bld, University of Melbourne, 3010, VIC
> Telephone +61 3 83446255 | Mobile +61 0407537949 | Email
> rlindsay@xxxxxxxxxxxxxx
>
> This email and any attachments may contain personal information or
> information that is otherwise confidential or the subject of copyright. Any
> use, disclosure or copying of any part of it is prohibited. The University
> does not warrant that this email or any attachments are free from viruses or
> defects. Please check any attachments for viruses and defects before opening
> them. If this email is received in error please delete it and notify us by
> return email.
>
>
> _______________________________________________
> xfs mailing list
> xfs@xxxxxxxxxxx
> http://oss.sgi.com/mailman/listinfo/xfs
>

<Prev in Thread] Current Thread [Next in Thread>