[stgt] Accidental iSCSI Targets Deleted

John P. Mitchell jpmitchell at alaska.edu
Tue Oct 15 21:06:23 CEST 2013


All,

    I was attempting to dump out the running configuration of the tgtd daemon the other day. I ran the command "tgt-admin -dump" instead of "tgt-admin --dump". Sadly I was multi-tasking at the time and looked away for a few moments only to look back and wonder why the command was taking so long. Well, long story short all of my targets on that host ended up being deleted. Fortunately the targets where only one side of a mirrored array and operations where not heavily impacted. I am using version 1.0.24 of tgt packaged by Red Hat from their RHEL 6 distro. I looked at the git tree and it does not look like it should do this in either the version I am running or the version that is current. I am wondering if this is a parameter parsing bug or if I should request a feature to prompt when deleting targets to protect from fat fingered moments. I do have a feature request in that the built-in help in the command does not mention "-d" as a valid argument which led me to be bewildered for a while until I looked at the man page for a bit. So it seems the introduction in the man page and the built-in help could use a bit more detail. I am happy to provide diffs for updating the man page and the help in the tgt-admin perl script if that would be welcome. I am not real familiar with the Getopt Perl library so I am not sure what I can do to help but I am willing to try. If I have some time I will spin up a VM and try to replicate my problem with the 1.0.24 version and the current version from git. Thanks!

--
John P. Mitchell
jpmitchell at alaska.edu
Systems Administrator/Programmer
Elmer E. Rasmuson Library
907.474.1128








More information about the stgt mailing list