We recreated a fileserver, which had an XFS filesystem using project quotas residing on a SAN. Unfortunately, we had forgotten to backup /etc/projects and /etc/projid on the server before reinstalling. The XFS filesystem itself, and the quota information stored therein, is all Ok AFAICS. Is there some way of figuring out the project ID's of the directories on disk, so that we can recreate /etc/{projects,projid}?
To clarify, lets say the XFS filesystem is mounted on /export/xfs and contains directories /export/xfs/foo and /export/xfs/bar. So we need to have the following entries in /etc/projects
NN:/export/xfs/foo
MM:/export/xfs/bar
and the following entries in /etc/projid
foo:NN
bar:MM
So how do we retrieve the values of NN and MM, which are stored on disk?