Re: Moving /var/cfengine

Beto <[email protected]> Thu, 27 Feb 2025 06:41:29 -0800 (PST)
Newsgroups gmane.comp.sysutils.cfengine.general
Message-ID <[email protected]>
------=_Part_48894_1571417107.1740667289978
Content-Type: multipart/alternative; 
	boundary="----=_Part_48895_770617665.1740667289978"

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

Hi Craig,

That's pretty much the process I was thinking of using.  I haven't tried it=
=20
yet as other priorities have taken over.  I'll post results once I get to=
=20
try it.

Thanks for replying!

On Tuesday, February 25, 2025 at 7:57:13=E2=80=AFAM UTC-6 craig.c...@northe=
rn.tech=20
wrote:

> 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 i=
s=20
> referred to as WORKDIR:
>
>
> https://docs.cfengine.com/docs/3.24/reference-special-variables-sys.html#=
sys-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 wit=
h=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/2ecc5903-030e-40e0-8fa1-552eb7dac571n%40googlegroups.com.

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

Hi Craig,<div><br /></div><div>That's pretty much the process I was thinkin=
g of using.=C2=A0 I haven't tried it yet as other priorities have taken ove=
r.=C2=A0 I'll post results once I get to try it.<br /><br />Thanks for repl=
ying!<br /><br /></div><div class=3D"gmail_quote"><div dir=3D"auto" class=
=3D"gmail_attr">On Tuesday, February 25, 2025 at 7:57:13=E2=80=AFAM UTC-6 c=
[email protected] wrote:<br/></div><blockquote class=3D"gmail_quote" =
style=3D"margin: 0 0 0 0.8ex; border-left: 1px solid rgb(204, 204, 204); pa=
dding-left: 1ex;">Hello!<div><br></div><div>Sorry this one hasn&#39;t had a=
ny responses. Did you figure something out?</div><div><br></div><div>This /=
var/cfengine path is hard-coded into CFEngine at compile time. It is referr=
ed to as WORKDIR:</div><div><br></div><div><a href=3D"https://docs.cfengine=
.com/docs/3.24/reference-special-variables-sys.html#sys-workdir" target=3D"=
_blank" rel=3D"nofollow" data-saferedirecturl=3D"https://www.google.com/url=
?hl=3Den&amp;q=3Dhttps://docs.cfengine.com/docs/3.24/reference-special-vari=
ables-sys.html%23sys-workdir&amp;source=3Dgmail&amp;ust=3D1740753489464000&=
amp;usg=3DAOvVaw2NqAKJ4wwSLbfSomz9GIfR">https://docs.cfengine.com/docs/3.24=
/reference-special-variables-sys.html#sys-workdir</a></div><div><br></div><=
div>If you need to migrate to new storage I might suggest this untested pro=
cedure:</div><div><br></div><div>- shut CFEngine down with something like `=
systemctl stop cfengine3`</div><div>- double-checking that all CFEngine rel=
ated processes 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 r=
sync to copy everything over: `rsync -avz /var/old-cfengine/ /var/cfengine/=
`</div><div>- restart services with `systemctl start cfengine3`</div><div><=
br></div><div>I haven&#39;t had occasion to perform such a migration so tak=
e this as a suggested course to be considered carefully as you plan.</div><=
div><br></div><div>Let us know how it goes or if you have more questions.</=
div><div><br></div><div>-Craig</div><div class=3D"gmail_quote"><div dir=3D"=
auto" class=3D"gmail_attr">On Friday, February 7, 2025 at 8:25:35=E2=80=AFA=
M UTC-6 Beto wrote:<br></div><blockquote class=3D"gmail_quote" style=3D"mar=
gin: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></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/2ecc5903-030e-40e0-8fa1-552eb7dac571n%40googlegroups.com?utm_=
medium=3Demail&utm_source=3Dfooter">https://groups.google.com/d/msgid/help-=
cfengine/2ecc5903-030e-40e0-8fa1-552eb7dac571n%40googlegroups.com</a>.<br /=
>

------=_Part_48895_770617665.1740667289978--

------=_Part_48894_1571417107.1740667289978--