...
Code Block |
---|
[root@TEST]# df -h Filesystem Size Used Avail Use% Mounted on /dev/mapper/vg_nmis64-lv_root 16G 11G 4.1G 73% / tmpfs 5.9G 0 5.9G 0% /dev/shm /dev/sda1 477M 75M 377M 17% /boot /dev/mapper/vg_nmis64_data-lv_data 246G 95G 139G 41% /data /dev/mapper/vg_nmis64-lv_var 20G 10G 8.3G 55% /var tmpfs 1000M 30M 971M 3% /media/ramdisk |
Step #3 - Disable NMIS
We need to disable NMIS so that it will not attempt to modify the files as we are point nmis8/var to the new RAM disk. Comment out any jobs in /etc/cron.d/nmis that may run during the next 20 minutes. Here's an example of a couple cron jobs that should be commented out.
Code Block |
---|
######################################################
# Run (selective) Statistics and Service Status Collection often
#* * * * * root /usr/local/nmis8/bin/nmis.pl type=collect mthread=true ; /usr/local/nmis8/bin/nmis.pl type=services mthread=true
######################################################
# Run Summary Update every 5 minutes
#*/5 * * * * root /usr/local/nmis8/bin/nmis.pl type=summary |
Option 42b
This is easily accomplished by placing a file called 'NMIS_IS_LOCKED' in the nmis8/conf directly as in the following example.
Code Block |
---|
Code Block |
[root@TEST]# touch /usr/local/nmis8/conf/NMIS_IS_LOCKED |
After these jobs have been disabled, Once the lock file is in place check the server for any nmis.pl processes.
Code Block |
---|
[root@TEST]# ps -ef | grep nmis.pl |
...
Code Block |
---|
ln -s /media/ramdisk/nmis8/var/ /usr/local/nmis8 |
Step #5 - Re-enable NMIS
...
Option 42c
Code Block |
---|
[root@TEST]# rm /usr/local/nmis8/conf/NMIS_IS_LOCKED |
...
Step #6 - Verify
move to the /usr/local/nmis8/var directory and execute a 'df -h .' command. This command should reveal that we are indeed on the ramdisk.
Code Block [root@TEST ~]# cd /usr/local/nmis8/var [root@TEST var]# df -h . Filesystem Size Used Avail Use% Mounted on tmpfs 1000M 30M 971M 3% /media/ramdisk [root@TEST var]#
- Take a look in the /usr/local/nmis8/var directory and confirm that node.json and view.json files have been created.
- Verify that the NMIS GUI is functioning normally.
...