2
0
mirror of https://github.com/xcat2/xcat-core.git synced 2026-11-21 01:42:15 +00:00
Commit Graph

16 Commits

Author SHA1 Message Date
Vinícius Ferrão 87c58da302 fix(packimage): take the image directory literally when removing files
The removal of abandoned stages, the removal of the other archive
formats after a publication, and rmimage found their files with glob.
glob splits a pattern at a space, so for an image directory such as
"/install/custom images/node" the first word named another path.
rmtree then removed that directory, with its images. glob also takes a
wildcard character in the path of the image directory as a pattern.

image_dir_entries now lists the image directory itself and matches the
names of its entries, and these removals use it.
2026-10-13 16:51:34 -03:00
Vinícius Ferrão e06910c1de fix(packimage): keep the staging that holds the previous archive
When a failed publication could not put back the previous archive or
metainfo, it moved them to a .rootimg-previous-* directory. When that
move failed too, they stayed in the staging directory, which packimage,
liteimg and imgimport then removed. The only copy of the previous files
was lost.

Staging that keeps a previous file now stays, and the error names it.
The removal of abandoned stages leaves it, and rmimage removes it with
the image. A publication removes its previous files from staging
otherwise, so only a failed one leaves them.
2026-10-13 16:51:33 -03:00
Vinícius Ferrão 2ec6029c95 fix(rmimage): remove the statelite archive and the checksum files
rmimage removed rootimg.* from the image directory. That missed rootimg-
statelite.gz with its checksum and metainfo, and the .rootimgcheck
marker of the initial ramdisk. A temporary directory that an interrupted
packimage, liteimg or imgimport left on this host also stayed, with a
partial archive in it.

rmimage now removes these files, the temporary directories that writers
on this host abandoned, and the .rootimg-previous-* directories that
failed publications kept. rootimg_stage and rmimage share this cleanup
through remove_abandoned_rootimg_stages.
2026-10-13 16:51:32 -03:00
GONG Jie 75b3d4c74a Remove trailing spaces in file xCAT-server/lib/xcat/plugins/rmimage.pm 2017-12-31 23:59:59 +00:00
immarvin 8686edb86d fix issue [CUSTOMER] Stale rootimg.gz file left in the rootimg dir caused node boot failed. #2225 2016-11-29 21:54:18 -05:00
immarvin 1ebdb5d96c add lock in rh/genimage to avoid multiple genimage processes on same rootimg directory;add guard code before umount/remove mount points under rootimg directory 2016-11-03 03:32:12 -04:00
Mark Gurevich 0a3fbd8d51 perltidy all perl files 2016-07-20 11:40:27 -04:00
huweihua bd2ee5c070 use lazy mode of umount to increase the success rate 2015-11-22 21:30:33 -05:00
huweihua c889383494 provide a walk around to defect #424 2015-11-21 03:01:39 -05:00
ligc c0f65b7ae7 remove install/netboot/statelite related flags from rmimage, liteimg and rinstall 2015-05-14 04:57:44 -04:00
Chuck Brazie ef75e82fe3 Merge zVM updates into xCAT 2.8.3 2013-10-21 14:01:20 -04:00
phamt cd4f866c6a In imgcapture, added option for specifying device to capture (only s390x). In rmimage, added support to remove provmethod = raw (native SCSI/FCP) images. In imgimport and imgexport, added remote host option to download from a node not managed by xCAT, fixed indentation issues, and added support for provmethod = raw (native SCSI/FCP device image)
git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@16697 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
2013-06-19 16:18:42 +00:00
linggao 2a5ae3d1b4 fixed SF bug #3392 rmimage removes tftpboot kernel file that may be used by other images
git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@15348 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
2013-03-01 19:11:29 +00:00
zhaoertao 40e144b4cc for item: clean up Utils.pm, the code in xCAT-server/lib/xcat/plugin/
git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@13467 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
2012-08-09 04:07:40 +00:00
daniceexi 48c280bae1 fix the issue that rootimg/sys was not umounted by genimage
git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@12184 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
2012-04-10 17:23:20 +00:00
ligc 138b9ec928 rmimage code drop
git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@7444 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
2010-09-14 08:22:36 +00:00