Re: Moving /var/cfengine

"'[email protected]' via help-cfengine" <[email protected]> Tue, 25 Feb 2025 05:57:12 -0800 (PST)
Newsgroups gmane.comp.sysutils.cfengine.general
Message-ID <[email protected]>
------=_Part_396532_1421804603.1740491832916
Content-Type: multipart/alternative; 
	boundary="----=_Part_396533_1845516327.1740491832916"

------=_Part_396533_1845516327.1740491832916
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

Hello!

Sorry this one hasn't had any responses. Did you figure something out?

This /var/cfengine path is hard-coded into CFEngine at compile time. It is=
=20
referred to as WORKDIR:

https://docs.cfengine.com/docs/3.24/reference-special-variables-sys.html#sy=
s-workdir

If you need to migrate to new storage I might suggest this untested=20
procedure:

- shut CFEngine down with something like `systemctl stop cfengine3`
- double-checking that all CFEngine related processes are not running with=
=20
something like `ps -efl | grep cf`
- moving the current directory aside: `mv /var/cfengine /var/old-cfengine`
- mounting your new storage as `/var/cfengine`
- using rsync to copy everything over: `rsync -avz /var/old-cfengine/=20
/var/cfengine/`
- restart services with `systemctl start cfengine3`

I haven't had occasion to perform such a migration so take this as a=20
suggested course to be considered carefully as you plan.

Let us know how it goes or if you have more questions.

-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.  I'm=
=20
> thinking of using rsync for this:
>
> rsync -avz /var/cfengine /var/new_cfengine
>
> Of course everything would first be shut down.
>
> Has anyone tried this?  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 e=
mail to [email protected].
To view this discussion visit https://groups.google.com/d/msgid/help-cfengi=
ne/786fa209-8ebb-4b32-9133-294976853655n%40googlegroups.com.

------=_Part_396533_1845516327.1740491832916
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

Hello!<div><br /></div><div>Sorry this one hasn't had any responses. Did yo=
u figure something out?</div><div><br /></div><div>This /var/cfengine path =
is hard-coded into CFEngine at compile time. It is referred to as WORKDIR:<=
/div><div><br /></div><div>https://docs.cfengine.com/docs/3.24/reference-sp=
ecial-variables-sys.html#sys-workdir</div><div><br /></div><div>If you need=
 to migrate to new storage I might suggest this untested procedure:</div><d=
iv><br /></div><div>- shut CFEngine down with something like `systemctl sto=
p cfengine3`</div><div>- double-checking that all CFEngine related processe=
s are not running with something like `ps -efl | grep cf`<br />- moving the=
 current directory aside: `mv /var/cfengine /var/old-cfengine`</div><div>- =
mounting your new storage as `/var/cfengine`</div><div>- using rsync to cop=
y everything over: `rsync -avz /var/old-cfengine/ /var/cfengine/`</div><div=
>- restart services with `systemctl start cfengine3`</div><div><br /></div>=
<div>I haven't had occasion to perform such a migration so take this as a s=
uggested course to be considered carefully as you plan.</div><div><br /></d=
iv><div>Let us know how it goes or if you have more questions.</div><div><b=
r /></div><div>-Craig</div><div class=3D"gmail_quote"><div dir=3D"auto" cla=
ss=3D"gmail_attr">On Friday, February 7, 2025 at 8:25:35=E2=80=AFAM UTC-6 B=
eto wrote:<br/></div><blockquote class=3D"gmail_quote" style=3D"margin: 0 0=
 0 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">I =
need to move an Enterprise hub to new storage on the same server.=C2=A0 I&#=
39;m thinking of using rsync for this:<div><br></div><div><font face=3D"Cou=
rier New">rsync -avz /var/cfengine /var/new_cfengine</font></div><div><br><=
/div><div>Of course everything would first be shut down.</div><div><br></di=
v><div>Has anyone tried this?=C2=A0 I have a low pain tolerance lol.</div><=
/blockquote></div>

<p></p>

-- <br />
You received this message because you are subscribed to the Google Groups &=
quot;help-cfengine&quot; group.<br />
To unsubscribe from this group and stop receiving emails from it, send an e=
mail to <a href=3D"mailto:[email protected]">help-=
[email protected]</a>.<br />
To view this discussion visit <a href=3D"https://groups.google.com/d/msgid/=
help-cfengine/786fa209-8ebb-4b32-9133-294976853655n%40googlegroups.com?utm_=
medium=3Demail&utm_source=3Dfooter">https://groups.google.com/d/msgid/help-=
cfengine/786fa209-8ebb-4b32-9133-294976853655n%40googlegroups.com</a>.<br /=
>

------=_Part_396533_1845516327.1740491832916--

------=_Part_396532_1421804603.1740491832916--