Skip to content
This repository has been archived by the owner on Nov 2, 2021. It is now read-only.

Change all paths from /opt to /usr/share #116

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from
Open

Conversation

gunnarx
Copy link
Member

@gunnarx gunnarx commented May 30, 2018

(Sorry, I pushed the branch on here instead of on a fork. But that can be cleaned up easily...)

Change all paths from /opt to /usr/share

/opt can't be used in an normal OS-tree compatible layout - program files should now reside under /usr.

/etc/opt/ changed to remove opt which looks odd there anyway: --> /etc/rvi/.

@gunnarx
Copy link
Member Author

gunnarx commented May 30, 2018

Build fails on some unit tests. The message don't immediately mention the paths so it can't be understood to be immediately relevant? I'm not sure if these are expected failures (existed already on develop branch, or not?). As far as I can tell, "develop" is the current branch but it's hard to be sure.

@tjamison
Copy link
Contributor

Develop is indeed the active branch. Last build was passing but that was almost a year ago. I'll poke Travis CI on dev to see if the issue is that some references have gone stale

@tjamison
Copy link
Contributor

Unit tests still pass for develop, so this isn't a case of stale references. Maybe a bad relative or absolute ref in unit tests?

@gunnarx
Copy link
Member Author

gunnarx commented May 31, 2018

OK, I'll take another look to see what was missed.

@mirzak
Copy link

mirzak commented Jun 1, 2018

Analyzing who is writing what and where on the GDP image.

It seems that RVI core is writing stuff relative to the install path, meaning it saves logs in /usr/share/rvi_core/log/lager/ once we update the install path to /usr/share.

When we enable libostree /usr will be read-only, meaning that we need to change the log path location.

Output from inotifywatch

root@qemux86-64:~# inotifywatch -v -t 60 -r /usr/
Establishing watches...
Setting up watch(es) on /usr/
OK, /usr/ is now being watched.
Total of 2281 watches.
Finished establishing watches, now collecting statistics.
Will listen for events for 60 seconds.
total  access  modify  close_nowrite  open  filename
54     18      0       18             18    /usr/lib/
30     0       30      0              0     /usr/share/rvi_core/log/lager/

@gunnarx
Copy link
Member Author

gunnarx commented Jun 6, 2018

It seems that RVI core is writing stuff relative to the install path, meaning it saves logs in /usr/share/rvi_core/log/lager/ once we update the install path to /usr/share.

I did a simple search/replace so probably an omission. Probably just update paths /usr/share/rvi_share/log (or whatever it is) to /var/log/rvi_core/.

Since we're closing this up, that was split up into a sub ticket GDP-795

/opt can't be used in an normal OS-tree compatible layout - program
files should now reside under /usr.

/etc/opt/<rvi config files> changed to remove opt which looks
odd there anyway: --> /etc/rvi/<config files>.

Also moved default log location to /run/log/rvi_core because
${target_dir}/log is not adequate when the installation (target) dir
is read-only.  Note that /run is non-persistent, so /var/log might be
preferred later.

Signed-off-by: Gunnar Andersson <[email protected]>
@gunnarx
Copy link
Member Author

gunnarx commented Jul 27, 2018

Amended to place logs by default in /run/var/logs. More info in commit.
(Presumably the -l flag should be specified by a real installation anyhow)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants