markh794 / mhvtl

Linux based Virtual Tape Library
http://sites.google.com/site/linuxvtl2/
Other
140 stars 65 forks source link

WORM capability doesn't work in mhvtl. #122

Open Mohit-orange opened 1 year ago

Mohit-orange commented 1 year ago

Hello Guys,

I created WORM tape using mktape command in mhvtl.

mktape -l 10 -m W00003LW -s 500 -t WORM -d LTO6 WORM

mktape -l 10 -m W00002LW -s 500 -t WORM -d LTO6 WORM

I can see both of them under /opt/mhvtl and in /etc/mhvtl/library.contents.10

image

image

However when i label them in WORM pool.These tapes don't get labeled as WORM tapes because they are still be seen as NON-WORM tapes.

image

I tried a lot but i think there is an issue in emulator (mhvtl). It's not WORM capable. If it is then it should label the WORM tape in the WORM pool.

Mohit-orange commented 1 year ago

Hello Mark ,

Possible for you to check ?

markh794 commented 1 year ago

Any chance of obtaining the syslog (/var/log/messages) ? I've only ever used NetBackup against WORM media - and that was several major versions ago. You should find the media behaves like worm - in that you can't rewind to previous block/filemark and attempt to re-write data. However, what mode page/log page updates should be performed may not be updated correctly. Hence the request for syslog - so I can see what pages are being requested from the backup application.

Thanks Mark

Mohit-orange commented 1 year ago

Hello Mark,

I have attched the /var/log/messages as you requested.

Moreover some information about the machine of mhvtl image

Mohit-orange commented 1 year ago

Log from the VTL [mhvtl] (/var/log/messages )messages.zip

Mohit-orange commented 1 year ago

Log from backup server ( /var/log/messages) messages.zip

Mohit-orange commented 1 year ago

Hello Mark,

Good morning !! Did you get chance to look into the logs attached ?

markh794 commented 1 year ago

Hello Mohit,

I've had a quick look at the logs and can't see anything stand out. While the screenshot went unrecognised - the logs show it is NetWorker. So, I thought I'd spin up a copy and see if I could recall how to set it up (it's been ~20yrs since I last seriously used nsr). Any hints on how to setup WORM would be good. I'm currently having troubles finding a CentOS version where I can actually install my copy (8.22) - all sorts of GLIBC-2.x errors when trying to install the RPMs.. I think I'm going to have to try and get a more recent version of NetWorker :)

markh794 commented 1 year ago

Can I confirm you are using the latest (github) version of mhVTL or a pre-built RPM ? If so - what version.

Mohit-orange commented 1 year ago

Hello Mark,

I am using mhvtl version 1.7

image

Mohit-orange commented 1 year ago

Hello Mark, Below is the procedure to setup WORM label, media pool for your ease.

Mohit-orange commented 1 year ago

At first we need to identify whether our device (tape-drive in our case) is WORM/DLTWORM capable or not. To check this in networker we can go to: Devices --> Libraries --> Select your library --> Choose or select a drive --> Properties. image Under device properties, Select Information tab and check WORM and DLTWORM capable parameter. image As you can see above, your device is WORM capable but not DLTWORM capable because it’s an LTO tape drive and not the DLT (digital Linear tape) tape drive. Networker automatically sets these attributes and, consequently, they are read-only and cannot be changed.

Creating a WORM media pool.

Create a Label template first to be used by WORM media pool. To achieve this, from your NMC select: Media --> Select Label Template --> right click --> Click New.

image Create label template window will appear. Choose the name of the Pool as WORM and fields as per your infra-requirement and click OK.

image

WORM label template created to be used for WORM pool as shown below.

image

To create WORM media pool, Select Media pools --> Right Click --> Click on New.

image

Create media pool window will appear. In General tab, Fill the Pool name, type, and label name. In Label template, Select the template WORM created by us earlier.

image

In the selection criteria tab, Select the drives which are WORM capable as per your requirement. You can set the target media type and media type preferred as per your tape and drive model and made. In my demo case, I am keeping it as by default (empty).

image

In configuration tab, make sure to check the WORM pool ticked under WORM configuration.

image

Keep the other fields as it is by default and click OK to create WORM media pool. Now we can see a WORM pool is created under media pools.

image

Now try to assign a WORM tape into WORM media pool. When we have a WORM tape/media available in our PTL then we don’t need to change the default properties of WORM tape handling parameter.Below is the default setting for WORM tape handling parameter.

image

Now we will try to label a WORM tape into a WORM pool created by us. Here in our demo environment, We have WORM tape available with barcode as W00003LW

Mohit-orange commented 1 year ago

Let me know what else do you need :-)

markh794 commented 1 year ago

Looks like NetWorker has come some way since jbconfig & nsradmin

Mohit-orange commented 1 year ago

Hello Mark,

Hope you are doing great now-a-days !! By any chance, Have you tried testing WORM ?

markh794 commented 1 year ago

I've got my hands on NetWorker 19.9 - I've not had a chance to install/configure it. Hopefully tomorrow..

markh794 commented 1 year ago

hmm... nsrd not starting for me..

markh794 commented 1 year ago

Screenshot 2023-08-21 at 17 26 27

Mohit-orange commented 1 year ago

Which all packages have you installed on server? You need to install client, extended client, storage node, authc, server and nmc package in the same order as I've written. Run and check if you are able to see all the packages with the command. rpm - qa | grep - i lgto

Mohit-orange commented 1 year ago

Later you need to configure authc and nmc after successfull installation.

markh794 commented 1 year ago

I actually left it to RPM to figure out install order :)

rpm -Uvh lgtoclnt-19.9.0.0-1.x86_64.rpm lgtoman-19.9.0.0-1.x86_64.rpm lgtonmc-19.9.0.0-1.x86_64.rpm lgtonode-19.9.0.0-1.x86_64.rpm lgtoserv-19.9.0.0-1.x86_64.rpm lgtoauthc-19.9.0.0-1.x86_64.rpm lgtoxtdclnt-19.9.0.0-1.x86_64.rpm 

The result is:

[root@mhvtlNetWorker ~]# rpm -qa --last | grep lgto
lgtoman-19.9.0.0-1.x86_64                     Thu 17 Aug 2023 16:13:34 JST
lgtonmc-19.9.0.0-1.x86_64                     Thu 17 Aug 2023 16:13:33 JST
lgtoserv-19.9.0.0-1.x86_64                    Thu 17 Aug 2023 16:13:29 JST
lgtoauthc-19.9.0.0-1.x86_64                   Thu 17 Aug 2023 16:13:20 JST
lgtoxtdclnt-19.9.0.0-1.x86_64                 Thu 17 Aug 2023 16:13:17 JST
lgtonode-19.9.0.0-1.x86_64                    Thu 17 Aug 2023 16:13:14 JST
lgtoclnt-19.9.0.0-1.x86_64                    Thu 17 Aug 2023 16:13:12 JST

I shall uninstall and re-install in the above order.

Re: configure authc & nmc Yep, installed latest JRE from Oracle and the configure steps appeared to be successful.

Mohit-orange commented 1 year ago

Good morning MArk,

Just saw your commens. You can refer the below txt file for installation steps:- Networker server Installation-Linux .txt

Mohit-orange commented 1 year ago

Hello Mark,

Hope you are doing good today. Wishing you a wonderful day ahead !!

Just wanted to know if you are gradually moving towards the testing :-)

markh794 commented 1 year ago

Sorry - still trying to get the NetWorker installed and running. I assume 'nsrd' should be running on the 'server' (It's an all-in-one setup). I can manually start 'nsrd' and nsradmin then connects. But nsrd doesn't start by itself via any 'systemd/rc scripts' I've forgotten how NW determines if it's the server or just a storage node. (or is that dependent on packages installed ?)

Mohit-orange commented 1 year ago

GM Mark,

YES, server package needs storage node package. As you said, it's all in one setup so you should have all the packages installed as I explained earlier. Please refer my installation steps notepad attached earlier to accomplish your installation. Moreover see recommended system specifications like ram, cpu and your disk space especially /opt for networker to be running.

Thanks.

On Tue, Aug 29, 2023, 6:16 AM Mark Harvey @.***> wrote:

Sorry - still trying to get the NetWorker installed and running. I assume 'nsrd' should be running on the 'server' (It's an all-in-one setup). I can manually start 'nsrd' and nsradmin then connects. But nsrd doesn't start by itself via any 'systemd/rc scripts' I've forgotten how NW determines if it's the server or just a storage node. (or is that dependent on packages installed ?)

— Reply to this email directly, view it on GitHub https://github.com/markh794/mhvtl/issues/122#issuecomment-1696611375, or unsubscribe https://github.com/notifications/unsubscribe-auth/AMW3AODIYIMO3PIDKJNWOOLXXU3VJANCNFSM6AAAAAA3MNREAA . You are receiving this because you authored the thread.Message ID: @.***>

Mohit-orange commented 1 year ago

System specification for my LAB networker backup server. Just for your reference.

image

Mohit-orange commented 1 year ago

systemctl stop gst

ps -ef | grep -i gst (make sure all the NMC processes are stopped for java-based networker management console)

systemctl stop networker (Stop networker)

ps -ef | grep -i nsr (no networker process should be running)

delete all temporary files under or from /nsr/tmp.

systemctl start networker (start networker )

tail -30f /nsr/logs/daemon.raw (monitor networker logs) (wait untill your storage node is in ready state)

ps -ef | grep -i nsr (make sure all networker processes are running)

systemctl start gst

ps -ef | grep -i gst

Login to the the NMC now.

Mohit-orange commented 1 year ago

Hello Mark,

Any positive news :-)

Mohit-orange commented 1 year ago

Hello Mark,

Hope you are doing great !!.

I just want to let you know that i am still waiting and relying on your testing with WORM.

Mohit-orange commented 1 year ago

Hello Mark ,

Good Afternoon ,Hope you are doing good !!

Do you have any update on the issue i reported to you ? Let me know if anything else is reuired from me .

Thanks & regrads, Mohit .

markh794 commented 1 year ago

Still having problems getting NetWorker to start up.

Any chance of confirming which NetWorker processes are actually running on the server node ?

I'm off for a couple of weeks without access to my computer. I'll be checking into it further when I get back.

Thanks for the patience. Mark

Mohit-orange commented 1 year ago

Good morning Mark,

Primarily,You should have following processes running on storage-node/Media server:-

image

Mohit-orange commented 1 year ago

Hello Mark,

Hope you are doing good !!

Any luck on mhvtl WORM feature testing with DELL-EMC networker ?

Thanks !!

Mohit-orange commented 1 year ago

Hello Mark,

Hope you are doing good !!

Any progress OR any luck on mhvtl WORM feature testing with DELL-EMC networker ?

Thanks !!

markh794 commented 1 year ago

Sorry, I've been challenged for 'free' time of late. Still haven't been able to get NetWorker to start up as "master".

malhotrag commented 1 month ago

I was trying WORM support with mhvtl and encountered a bug that caused tapes to be created as non-worm by make_vtl_media. I have fixed the issue in #139.

You can use "dump_tape -m \<barcode>" to check if the tapes have been created as WORM. The dump_tape output for a WORM tape will show: Media type : Write Once Read Many (WORM)

The dump_tape output for a non-worm tape will show: Media type : Normal data