Article ID: 126345, created on Jul 27, 2015, last review on Jul 27, 2015

  • Applies to:
  • Virtuozzo


All file operations on Virtuozzo Storage are logged by pstorage-mount process into corresponding log files inside /var/log/pstorage directory. The logs are very detailed to read, so it is often required to trace the calls for a specific file only. The instructions below describe how to do it:

  1. Obtain the directory inode, where the file is located:

    [root@vz ~]# ls -ild /pstorage/cluster/vmprivate/testvm.pvm/
    7795153 drwx------ 1 root root 0 Jun 22 16:06 /pstorage/cluster/vmprivate/testvm.pvm/
  2. Obtain the file inode:

    [root@vz ~]# ls -il /pstorage/cluster/vmprivate/testvm.pvm/config.pvs
    7795265 -rwx------ 1 root root 18301 Jul 25 09:25 /pstorage/cluster/vmprivate/testvm.pvm/config.pvs
  3. Convert the inode numbers into HEX format:

    7795153 = 76F1D1
    7795265 = 76F241
  4. Compose the pattern to search for in the following format:

    [root@vz ~]# zgrep -i -E '[0076f1d1]/config.pvs|76F241' /var/log/pstorage/cluster/pstorage-mount.log.gz.{9..0} /var/log/pstorage/cluster/pstorage-mount.log.gz >> config.pvs.log

    The command searches for all appearances of the file chronologically, from the oldest log to the newest.

0dd5b9380c7d4884d77587f3eb0fa8ef 2897d76d56d2010f4e3a28f864d69223

Email subscription for changes to this article
Save as PDF