Re: Re: Moving /var/cfengine
"'Vratislav Podzimek' via help-cfengine" <[email protected]> Thu, 27 Feb 2025 23:06:20 +0100
| Newsgroups | gmane.comp.sysutils.cfengine.general |
|---|---|
| Message-ID | <[email protected]> |
On Thu, 2025-02-27 at 12:17 -0800, 'Nick Anderson' via help-cfengine wrote: > Weird, I have some memory of answering similar within the past few weeks.= Maybe my flesh brain is breaking down. >=20 > selinux contexts might not be handled with that but that's the only thing= that jumps to mind. Yes, SELinux contexts and ACLs. Check man:rsync(1) for options to use, `-a` alone won't be enough. -- Vratislav >=20 > On Thursday, February 27, 2025 at 8:41:30=E2=80=AFAM UTC-6 Beto wrote: > > Hi Craig, > >=20 > > That's pretty much the process I was thinking of using.=C2=A0 I haven't= tried it yet as other priorities have taken over.=C2=A0 I'll post results = once I get to try it. > >=20 > > Thanks for replying! > >=20 > > On Tuesday, February 25, 2025 at 7:57:13=E2=80=AFAM UTC-6 craig.c...@no= rthern.tech wrote: > > > Hello! > > >=20 > > > Sorry this one hasn't had any responses. Did you figure something out= ? > > >=20 > > > This /var/cfengine path is hard-coded into CFEngine at compile time. = It is referred to as WORKDIR: > > >=20 > > > https://docs.cfengine.com/docs/3.24/reference-special-variables-sys.h= tml#sys-workdir > > >=20 > > > If you need to migrate to new storage I might suggest this untested p= rocedure: > > >=20 > > > - shut CFEngine down with something like `systemctl stop cfengine3` > > > - double-checking that all CFEngine related processes are not running= with something like `ps -efl | grep cf` > > > - moving the current directory aside: `mv /var/cfengine /var/old-cfen= gine` > > > - mounting your new storage as `/var/cfengine` > > > - using rsync to copy everything over: `rsync -avz /var/old-cfengine/= /var/cfengine/` > > > - restart services with `systemctl start cfengine3` > > >=20 > > > I haven't had occasion to perform such a migration so take this as a = suggested course to be considered carefully as you plan. > > >=20 > > > Let us know how it goes or if you have more questions. > > >=20 > > > -Craig > > > On Friday, February 7, 2025 at 8:25:35=E2=80=AFAM UTC-6 Beto wrote: > > > > I need to move an Enterprise hub to new storage on the same server.= =C2=A0 I'm thinking of using rsync for this: > > > >=20 > > > > rsync -avz /var/cfengine /var/new_cfengine > > > >=20 > > > > Of course everything would first be shut down. > > > >=20 > > > > Has anyone tried this?=C2=A0 I have a low pain tolerance lol. > --=20 > You received this message because you are subscribed to the Google Groups= "help-cfengine" group. > To unsubscribe from this group and stop receiving emails from it, send an= email to [email protected]. > To view this discussion visit https://groups.google.com/d/msgid/help-cfen= gine/bdcbbef4-1df8-4ac2-8078-4eacb71522a6n%40googlegroups.com. --=20 You received this message because you are subscribed to the Google Groups "= help-cfengine" group. To unsubscribe from this group and stop receiving emails from it, send an e= mail to [email protected]. To view this discussion visit https://groups.google.com/d/msgid/help-cfengi= ne/88f7c07b751e7cb8e1f5247ef0a233c4bd058b90.camel%40northern.tech.