View previous topic :: View next topic |
Author |
Message |
mcnutty Tux's lil' helper
Joined: 29 Dec 2009 Posts: 138
|
Posted: Wed Dec 11, 2024 3:43 pm Post subject: cfg-update not not working correctly [Solved] |
|
|
I'm not sure exactly when or why, but 'cfg-update -u' no longer works consistently on my system.
When I run it it will identify the conflicting config files as normal, e.g.,:
Code: | 12/11/2024 07:28:32$ cfg-update -u
12/11/2024 07:28:52
Searching for updates...
<< Stage1 >> 0 files in queue for automatic replacing, skipping...
<< Stage2 >> 0 files in queue for automatic 3-way merging, skipping...
<< Stage3 >> 0 files in queue for manual 3-way merging, skipping...
<< Stage4 >> 2 files in queue for manual 2-way merging, starting...
(1/2) /etc/portage/package.use/steam *Custom File
* YOU ARE ABOUT TO UPDATE A CUSTOM FILE. YOU SHOULD ASK YOURSELF
* WHERE DOES IT COME FROM AND WHAT HAPPENDS WHEN YOU REPLACE IT?
* PORTAGE DID NOT INSTALL THE CURRENT FILE, MOST LIKELY IT HAS BEEN
* CREATED AFTER INSTALLATION AND IT MAY CONTAIN CUSTOM SETTINGS.
Press [y] - to merge the current file and the ._cfg0000_* file with kdiff3
Press [s] - to skip this update (to investigate first, and try again later)
Press [1] - to use the ._cfg0000_* file
Press [2] - to remove the ._cfg0000_* file
Press [q] - to quit cfg-update immediately
Merge manually with file : /etc/portage/package.use/._cfg0000_steam ? [y|s|1|2|q]
In kdiff3 you select the lines that you want to keep.
When done, click the save button and exit kdiff3!
When you exit kdiff3, cfg-update will finish the update... |
But when I enter 'y', it will bring up kdiff with an empty diff and a dialog that says 0 diffs were found. After clicking ok to the first dialog, a second dialog opens saying (in this example), "Opening of these files failed: /etc/portage/package.use/._cfg0000_steam"
Sometimes rebooting and trying again works and sometimes not. Does anyone know what's going on and how to fix it?
P.S. Sorry, if this posts more than once. After hitting submit I keep getting a message saying something like "Error in posting", and then I don't see my message in the forum. (It appears certain Unicode characters are not allowed and removing them let the post go through)
Last edited by mcnutty on Wed Dec 11, 2024 7:26 pm; edited 1 time in total |
|
Back to top |
|
|
freke Veteran
Joined: 23 Jan 2003 Posts: 1035 Location: Somewhere in Denmark
|
Posted: Wed Dec 11, 2024 4:05 pm Post subject: |
|
|
Permissions issue? - what user is running cfg-update? |
|
Back to top |
|
|
grknight Retired Dev
Joined: 20 Feb 2015 Posts: 1945
|
Posted: Wed Dec 11, 2024 4:08 pm Post subject: |
|
|
Next time this happens, Choose 's' to skip and then examine both /etc/portage/package.use/steam and /etc/portage/package.use/._cfg0000_steam .
Consider both the contents and the permissions.
Often, files like these are the target of the --autounmask-write option. Personally, I manage my package.use files by hand and disable this functionality.
If you need further help, post the contents of both files here when it occurs again. |
|
Back to top |
|
|
mcnutty Tux's lil' helper
Joined: 29 Dec 2009 Posts: 138
|
Posted: Wed Dec 11, 2024 4:47 pm Post subject: |
|
|
The permissions look ok to me:
Code: | root>ls /etc/portage/package.use/steam
-rw-r--r-- 1 root root 2.1K Jul 28 17:05 /etc/portage/package.use/steam
root>ls /etc/portage/package.use/._cfg0000_steam
-rw-r--r-- 1 root root 2.2K Dec 11 07:25 /etc/portage/package.use/._cfg0000_steam |
And the contents are identical as far as I can tell:
Code: |
root>diff /etc/portage/package.use/._cfg0000_steam /etc/portage/package.use/._cfg0000_steam
[no output] |
I'm reading through the man page about the various autounmask options and they mostly make sense. I don't think I've ever explicitly enabled --autounmask (or any subflag). However, it's possible when I emerged steam (and a few other packages) it asked me if I wanted to automatically add the use flags and I said yes, even though I usually manually copy and paste them to new or existing files.
Is there a way to get back to managing all my use flags manually? |
|
Back to top |
|
|
mcnutty Tux's lil' helper
Joined: 29 Dec 2009 Posts: 138
|
Posted: Wed Dec 11, 2024 4:55 pm Post subject: |
|
|
freke wrote: | Permissions issue? - what user is running cfg-update? |
Running cfg-update as roo. |
|
Back to top |
|
|
pingtoo Veteran
Joined: 10 Sep 2021 Posts: 1321 Location: Richmond Hill, Canada
|
Posted: Wed Dec 11, 2024 4:58 pm Post subject: |
|
|
May be you want to review you test
your ls show very different size 2.1k vs 2.2k.
And you diff compare same file.
mcnutty wrote: | The permissions look ok to me:
Code: | root>ls /etc/portage/package.use/steam
-rw-r--r-- 1 root root 2.1K Jul 28 17:05 /etc/portage/package.use/steam
root>ls /etc/portage/package.use/._cfg0000_steam
-rw-r--r-- 1 root root 2.2K Dec 11 07:25 /etc/portage/package.use/._cfg0000_steam |
And the contents are identical as far as I can tell:
Code: |
root>diff /etc/portage/package.use/._cfg0000_steam /etc/portage/package.use/._cfg0000_steam
[no output] |
I'm reading through the man page about the various autounmask options and they mostly make sense. I don't think I've ever explicitly enabled --autounmask (or any subflag). However, it's possible when I emerged steam (and a few other packages) it asked me if I wanted to automatically add the use flags and I said yes, even though I usually manually copy and paste them to new or existing files.
Is there a way to get back to managing all my use flags manually? |
|
|
Back to top |
|
|
mcnutty Tux's lil' helper
Joined: 29 Dec 2009 Posts: 138
|
Posted: Wed Dec 11, 2024 5:22 pm Post subject: |
|
|
pingtoo wrote: | May be you want to review you test
your ls show very different size 2.1k vs 2.2k.
And you diff compare same file.
|
Thanks!
Code: | root>diff /etc/portage/package.use/._cfg0000_steam /etc/portage/package.use/steam
17,18c17
< # move sys-devel/llvm llvm-core/llvm
< llvm-core/llvm abi_x86_32
---
> sys-devel/llvm abi_x86_32
38,39c37
< # move sys-devel/clang llvm-core/clang
< llvm-core/clang abi_x86_32
---
> sys-devel/clang abi_x86_32
|
I am still stuck on how to resolve this though. |
|
Back to top |
|
|
freke Veteran
Joined: 23 Jan 2003 Posts: 1035 Location: Somewhere in Denmark
|
Posted: Wed Dec 11, 2024 6:30 pm Post subject: |
|
|
Is it a matter of shell used? (what shell is used?)
I haven't seen command-prompts like that. |
|
Back to top |
|
|
logrusx Advocate
Joined: 22 Feb 2018 Posts: 2500
|
Posted: Wed Dec 11, 2024 6:56 pm Post subject: |
|
|
mcnutty wrote: |
I am still stuck on how to resolve this though. |
Up until now I knew about etc-update but never heard of cfg-update. I use dispatch-conf however. Try it or etc-update.
p.s. check if there are more ._cfg files.
Best Regards,
Georgi |
|
Back to top |
|
|
mcnutty Tux's lil' helper
Joined: 29 Dec 2009 Posts: 138
|
Posted: Wed Dec 11, 2024 7:09 pm Post subject: |
|
|
freke wrote: | Is it a matter of shell used? (what shell is used?)
I haven't seen command-prompts like that. |
I use bash. The command prompt 'root>' is just a mockup. My actual prompt contains Unicode that the forums don't accept. |
|
Back to top |
|
|
mcnutty Tux's lil' helper
Joined: 29 Dec 2009 Posts: 138
|
Posted: Wed Dec 11, 2024 7:11 pm Post subject: |
|
|
logrusx wrote: | mcnutty wrote: |
I am still stuck on how to resolve this though. |
Up until now I knew about etc-update but never heard of cfg-update. I use dispatch-conf however. Try it or etc-update.
p.s. check if there are more ._cfg files.
Best Regards,
Georgi |
I've been using cfg-update without any (major) issues for at least 15 years. I don't like dispatch-conf or etc-update and don't really want to change. |
|
Back to top |
|
|
mcnutty Tux's lil' helper
Joined: 29 Dec 2009 Posts: 138
|
Posted: Wed Dec 11, 2024 7:26 pm Post subject: |
|
|
After some more investigation, my current best guess is kdiff3 is the problem. Running kdiff3 manually on the command line
Code: | root>kdiff3 /etc/portage/package.use/._cfg0000_steam /etc/portage/package.use/steam |
produces the same error as with cfg-update. However, using a different tool on the command line e.g., meld, works just fine. Strangely, running kdiff3 without arguments and then selecting the files from the GUI works just fine. Also running:
Code: | root>cfg-update -u -t meld |
works as expected. |
|
Back to top |
|
|
logrusx Advocate
Joined: 22 Feb 2018 Posts: 2500
|
Posted: Wed Dec 11, 2024 8:31 pm Post subject: |
|
|
mcnutty wrote: | and don't really want to change. |
I'm sorry, I thought you had a different problem :)
mcnutty wrote: | After some more investigation, my current best guess is kdiff3 is the problem. Running kdiff3 manually on the command line
Code: | root>kdiff3 /etc/portage/package.use/._cfg0000_steam /etc/portage/package.use/steam |
produces the same error as with cfg-update. However, using a different tool on the command line e.g., meld, works just fine. Strangely, running kdiff3 without arguments and then selecting the files from the GUI works just fine. Also running:
Code: | root>cfg-update -u -t meld |
works as expected. |
That actually speaks for a change needed in cfg-update. A bug might be helpful.
Best Regards,
Georgi |
|
Back to top |
|
|
|