Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Troubleshooting cfg-update..
View unanswered posts
View posts from last 24 hours

Goto page Previous  1, 2, 3, 4, 5, 6, 7, 8  
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo
View previous topic :: View next topic  
Author Message
xentric
Guru
Guru


Joined: 16 Mar 2003
Posts: 410
Location: Netherlands

PostPosted: Tue Jan 31, 2006 9:56 pm    Post subject: Reply with quote

rickj wrote:
Does anyone have any suggestions?
Just unmerge cfg-update and follow the installation instructions in this post to install the latest version (1.8.0-r3) which doesn't have these problems with dependencies...
_________________
When all else fails, read the manual...
Registered Linux User #340626
Back to top
View user's profile Send private message
rickj
Guru
Guru


Joined: 06 Feb 2003
Posts: 427
Location: Calgary, Alberta, Canada

PostPosted: Wed Feb 01, 2006 4:30 pm    Post subject: Reply with quote

Thanks xentric, this worked perfectly.
Back to top
View user's profile Send private message
Sugob
n00b
n00b


Joined: 19 Feb 2006
Posts: 4

PostPosted: Sun Feb 19, 2006 3:46 pm    Post subject: Reply with quote

I know it isn't really a bug, but what script do you use to delete all
._new-cfg_* and ._old-cfg_*?
Back to top
View user's profile Send private message
xentric
Guru
Guru


Joined: 16 Mar 2003
Posts: 410
Location: Netherlands

PostPosted: Sun Feb 19, 2006 11:00 pm    Post subject: Reply with quote

Sugob wrote:
I know it isn't really a bug, but what script do you use to delete all
._new-cfg_* and ._old-cfg_*?


You can use something like this:
Code:
for i in `find /etc -name ._???-cfg_*`; do rm -rf $i; done
for i in `find /usr -name ._???-cfg_*`; do rm -rf $i; done

_________________
When all else fails, read the manual...
Registered Linux User #340626
Back to top
View user's profile Send private message
spacemunky
n00b
n00b


Joined: 22 May 2004
Posts: 35

PostPosted: Thu Mar 09, 2006 3:40 am    Post subject: xxdiffrc Reply with quote

Hi,

Firstly, what a great app - I've only been using cfg-update for a few minutes and I like it so much more than alternatives.

I have an xxdiff question - everytime cfg-update fires up xxdiff the default font is tiny and I have to manually change the font size. I've tried adding FontText: "Helvetica,13,-1,5,50,0,0,0,0,0" to my .xxdiffrc file but it's not helping, possibly because it doesn't conform to the syntax outlined in the manual: FontText: "<xfld-font-spec>"

Any ideas/suggestions?

Cheers!
Back to top
View user's profile Send private message
xentric
Guru
Guru


Joined: 16 Mar 2003
Posts: 410
Location: Netherlands

PostPosted: Thu Mar 09, 2006 7:15 pm    Post subject: Re: xxdiffrc Reply with quote

spacemunky wrote:
I have an xxdiff question - everytime cfg-update fires up xxdiff the default font is tiny and I have to manually change the font size. I've tried adding FontText: "Helvetica,13,-1,5,50,0,0,0,0,0" to my .xxdiffrc file but it's not helping, possibly because it doesn't conform to the syntax outlined in the manual: FontText: "<xfld-font-spec>"

Any ideas/suggestions?

The only thing I could find is the following bugreport.
http://bugs.donarmstrong.com/cgi-bin/bugreport.cgi?bug=299271
But looking at the FontText-string you've already tried, you probably have found that
bugreport before asking here... If you find a solution, please post it here. I'm curious
what causes this weird bug in xxdiff.

You can also try kdiff3 if you can't get xxdiff the way you like it.
_________________
When all else fails, read the manual...
Registered Linux User #340626
Back to top
View user's profile Send private message
saintdev
n00b
n00b


Joined: 13 Jul 2004
Posts: 60
Location: CO, USA

PostPosted: Thu Dec 14, 2006 4:47 am    Post subject: Reply with quote

I'm attempting ot use cfg-update with meld, everything seems to work fine, except when I save the new config file. cfg-update just gives me a message "update canceled" and leaves all the files sitting around just as they were. Is there something I need to do besides saving over the original config file, like it says to?
Code:
 # cfg-update -u

<< Stage1 >> 0 files in queue, skipping...

<< Stage2 >> 0 files in queue, skipping...

<< Stage3 >> 1 files in queue, starting...

(1/1)  /etc/._cfg0000_rc.conf  [Modified File]
* YOU ARE ABOUT TO UPDATE A MODIFIED FILE WHICH PROBABLY CONTAINS
* CUSTOM SETTINGS. YOU ARE FORCED TO UPDATE MANUALLY!
  Found an update for /etc/rc.conf
  Press [y] - to merge the current file and the ._cfg????_* file with xxdiff
  Press [s] - to skip this update (to investigate first, and try again later)
  Press [q] - to quit cfg-update immediately
  Merge manually with file : /etc/._cfg0000_rc.conf ? [y|s|q] y
  (meld)      when done, save the merged result over the current config file by
  (meld)      right-clicking on the left pane and chosing "Save"!
Update canceled...

<< Stage4 >> 0 files in queue, skipping...

<< Stage5 >> 0 files in queue, skipping...

1 updates remaining, run cfg-update again until all files are updated!

_________________
> SELECT `signature` FROM `members` WHERE `user_name`='saintdev';
0 rows returned.
Back to top
View user's profile Send private message
xentric
Guru
Guru


Joined: 16 Mar 2003
Posts: 410
Location: Netherlands

PostPosted: Thu Dec 14, 2006 7:01 am    Post subject: Reply with quote

saintdev wrote:
I'm attempting ot use cfg-update with meld, everything seems to work fine, except when I save the new config file. cfg-update just gives me a message "update canceled" and leaves all the files sitting around just as they were. Is there something I need to do besides saving over the original config file, like it says to?

Cfg-update does two checks when the mergetool (meld in this case) is closed by you:
1. it checks if it can find foo.merge (where foo is the filename you are updating)
2. if foo.merge is not found, it checks if the foo file itself has been changed (when saving over the original file)
If no changes are found, cfg-update should ask what to do with the ._cfg0000_foo file.
(the older versions do not ask what to do when no changes are found)

So I guess you didn't change anything in the original file and you are using an older version of cfg-update.
If this is not the case, please tell me exactly what you did in meld...
_________________
When all else fails, read the manual...
Registered Linux User #340626
Back to top
View user's profile Send private message
saintdev
n00b
n00b


Joined: 13 Jul 2004
Posts: 60
Location: CO, USA

PostPosted: Fri Dec 15, 2006 4:32 am    Post subject: Reply with quote

xentric wrote:
Cfg-update does two checks when the mergetool (meld in this case) is closed by you:
1. it checks if it can find foo.merge (where foo is the filename you are updating)
2. if foo.merge is not found, it checks if the foo file itself has been changed (when saving over the original file)
If no changes are found, cfg-update should ask what to do with the ._cfg0000_foo file.
(the older versions do not ask what to do when no changes are found)

So I guess you didn't change anything in the original file and you are using an older version of cfg-update.
If this is not the case, please tell me exactly what you did in meld...


I have changed the file, in fact I've changed it back and forth attempting to get cfg-update to recognize that it has been changed. cfg-update reports it's version as 1.8.0-r3 which is the latest version available in portage.

Here's what I did:
Used sux to become root. Ran cfg-update -u
http://saintdevelopment.com/images/cfg-update/cfg-update-1.png

Press 'y' to launch mergetool (meld)
http://saintdevelopment.com/images/cfg-update/cfg-update-2.png

Copy the change from the update to the existing config
http://saintdevelopment.com/images/cfg-update/cfg-update-3.png

Save the updated config over the existing config
http://saintdevelopment.com/images/cfg-update/cfg-update-4.png

cfg-update says 'Update canceled...'
http://saintdevelopment.com/images/cfg-update/cfg-update-5.png

As far as I can tell I'm doing everything right, but please correct me if I am doing anything incorrect.
_________________
> SELECT `signature` FROM `members` WHERE `user_name`='saintdev';
0 rows returned.
Back to top
View user's profile Send private message
xentric
Guru
Guru


Joined: 16 Mar 2003
Posts: 410
Location: Netherlands

PostPosted: Fri Dec 15, 2006 7:16 am    Post subject: Reply with quote

saintdev wrote:
Here's what I did:
Used sux to become root. Ran cfg-update -u
Press 'y' to launch mergetool (meld)
Copy the change from the update to the existing config
Save the updated config over the existing config
cfg-update says 'Update canceled...'
As far as I can tell I'm doing everything right, but please correct me if I am doing anything incorrect.

Yes, you're not doing anything wrong.

OK, try this: Maximise your xterm/konsole window and do the same thing but now with "cfg-update -du", which makes cfg-update output debugging info.
Don't be intimidated by the massive amount of output, cfg-update still asks the same questions.
If you post that output I can see exactly which subroutines are called or skipped...

We'll figure this out :D
_________________
When all else fails, read the manual...
Registered Linux User #340626
Back to top
View user's profile Send private message
saintdev
n00b
n00b


Joined: 13 Jul 2004
Posts: 60
Location: CO, USA

PostPosted: Sat Dec 16, 2006 2:41 am    Post subject: Reply with quote

xentric wrote:
Yes, you're not doing anything wrong.

OK, try this: Maximise your xterm/konsole window and do the same thing but now with "cfg-update -du", which makes cfg-update output debugging info.
Don't be intimidated by the massive amount of output, cfg-update still asks the same questions.
If you post that output I can see exactly which subroutines are called or skipped...

We'll figure this out :D

Here you are:
Code:
wu-ming ~ # cfg-update -du
________________________________________________________________________________

cfg-update 1.8.0-r3 : Debugging mode enabled...
________________________________________________________________________________

*** Settings *******************************************************************

  mergetool     = /usr/bin/meld
  backups       = yes
  enable_stage1 = yes
  enable_stage2 = yes
  enable_stage3 = yes
  enable_stage4 = yes
  enable_stage5 = yes
  aliasfile     = /root/.bashrc
  aliascmd      = emerge_with_indexing_for_cfg-update
  portageconfig = /etc/make.conf
  progdir       = /usr/lib/cfg-update
  indexfile     = /usr/lib/cfg-update/checksum.index
  config_new    = ._cfg????_*
  rm_new        = \._cfg...._
  temp_new      = ._temp-new-cfg_*
  backup_new    = ._new-cfg_*
  restore_new   = ._cfg0000_*
  rm_old        = \._old-cfg_
  temp_old      = ._temp-old-cfg_*
  backup_old    = ._old-cfg_*
  restore_old   = *
  merged        = *.merge

*** Flags **********************************************************************

  opt_a = 0
  opt_d = 1
  opt_m = 0
  opt_p = 0
  opt_t = 
  opt_v = 0

*** Executing ******************************************************************

<root_only>
      id -u
</root_only>
<update_files>
   
    <find_protected_dirs>
          portageq config_protect
    </find_protected_dirs>
    <find_updates>
          find /etc -name '._cfg????_*'  | sort
          find /usr/kde/3.5/share/config -name '._cfg????_*'  | sort
          find /usr/share/config -name '._cfg????_*'  | sort
          find /usr/share/X11/xkb -name '._cfg????_*'  | sort
    </find_updates>
    <schedule_automatic_updates>
        <prepare_filename_for_updating>
        </prepare_filename_for_updating>
        <determine_state>
              md5sum /etc/rc.conf  | awk '{ print $1 }'
              MD5 checksum of current config file : b51f74babb72402cac08286de1930e25
              cat /usr/lib/cfg-update/checksum.index | grep "/etc/rc.conf " | awk '{ print $2 }'
              MD5 checksum in the checksum-index  : d822a2548ee1b0e7206e622869d2a11a
        </determine_state>
    </schedule_automatic_updates>
    <update_stage1>
        << Stage1 >> 0 files in queue, skipping...

    </update_stage1>
    <update_stage2>
        << Stage2 >> 0 files in queue, skipping...

    </update_stage2>
    <check_tool>
    </check_tool>
    <find_updates>
          find /etc -name '._cfg????_*'  | sort
          find /usr/kde/3.5/share/config -name '._cfg????_*'  | sort
          find /usr/share/config -name '._cfg????_*'  | sort
          find /usr/share/X11/xkb -name '._cfg????_*'  | sort
    </find_updates>
    <schedule_manual_updates>
        <prepare_filename_for_updating>
        </prepare_filename_for_updating>
        <determine_state>
              md5sum /etc/rc.conf  | awk '{ print $1 }'
              MD5 checksum of current config file : b51f74babb72402cac08286de1930e25
              cat /usr/lib/cfg-update/checksum.index | grep "/etc/rc.conf " | awk '{ print $2 }'
              MD5 checksum in the checksum-index  : d822a2548ee1b0e7206e622869d2a11a
        </determine_state>
    </schedule_manual_updates>
    <update_stage3>
        << Stage3 >> 1 files in queue, starting...

        <prepare_filename_for_updating>
        </prepare_filename_for_updating>
        <determine_state>
              md5sum /etc/rc.conf  | awk '{ print $1 }'
              MD5 checksum of current config file : b51f74babb72402cac08286de1930e25
              cat /usr/lib/cfg-update/checksum.index | grep "/etc/rc.conf " | awk '{ print $2 }'
              MD5 checksum in the checksum-index  : d822a2548ee1b0e7206e622869d2a11a
        </determine_state>
        <make_temp_backups>
        </make_temp_backups>
        <md5sum>
              md5sum /etc/rc.conf  | awk '{ print $1 }'
        </md5sum>
        <md5sum>
              md5sum /etc/._cfg0000_rc.conf  | awk '{ print $1 }'
        </md5sum>
        (1/1)  /etc/._cfg0000_rc.conf  [Modified File]
        <show_warning>
            * YOU ARE ABOUT TO UPDATE A MODIFIED FILE WHICH PROBABLY CONTAINS
            * CUSTOM SETTINGS. YOU ARE FORCED TO UPDATE MANUALLY!
        </show_warning>
          Found an update for /etc/rc.conf
          Press [y] - to merge the current file and the ._cfg????_* file with xxdiff
          Press [s] - to skip this update (to investigate first, and try again later)
          Press [q] - to quit cfg-update immediately
          Merge manually with file : /etc/._cfg0000_rc.conf ? [y|s|q]         <readkey>
y           
        </readkey>
        <tool_intro>
              (meld)      when done, save the merged result over the current config file by
              (meld)      right-clicking on the left pane and chosing "Save"!
        </tool_intro>
        <launch_tool>
              /usr/bin/meld /etc/rc.conf /etc/._new-cfg_rc.conf /etc/._cfg0000_rc.conf

(meld:31859): GnomeUI-WARNING **: While connecting to session manager:
Authentication Rejected, reason : None of the authentication protocols specified are supported and host-based authentication failed.
        </launch_tool>
        <tool_outro>
        </tool_outro>
          cat /etc/rc.conf.merge  | grep "^<<<<<<< \|\^||||||\|\^>>>>>>> \|\^=======$"
        <update_canceled>
            Update canceled...

        </update_canceled>
    </update_stage3>
    <update_stage4>
        << Stage4 >> 0 files in queue, skipping...

    </update_stage4>
    <update_stage5>
        << Stage5 >> 0 files in queue, skipping...

    </update_stage5>
</update_files>
<done>
    <find_updates>
          find /etc -name '._cfg????_*'  | sort
          find /usr/kde/3.5/share/config -name '._cfg????_*'  | sort
          find /usr/share/config -name '._cfg????_*'  | sort
          find /usr/share/X11/xkb -name '._cfg????_*'  | sort
    </find_updates>
1 updates remaining, run cfg-update again until all files are updated!

</done>

_________________
> SELECT `signature` FROM `members` WHERE `user_name`='saintdev';
0 rows returned.
Back to top
View user's profile Send private message
xentric
Guru
Guru


Joined: 16 Mar 2003
Posts: 410
Location: Netherlands

PostPosted: Sat Dec 16, 2006 10:36 am    Post subject: Reply with quote

Quote:
(meld:31859): GnomeUI-WARNING **: While connecting to session manager:
Authentication Rejected, reason : None of the authentication protocols specified are supported and host-based authentication failed.
This is probably causing problems when saving your changes. I probably means that meld did not get root rights and cannot save the file.

I have included sux as a dependency to the ebuild because it fixes almost all authentication problems.
So try becoming root with "sux" instead of "su" or "sudo" and try "cfg-update -u" again.
_________________
When all else fails, read the manual...
Registered Linux User #340626
Back to top
View user's profile Send private message
saintdev
n00b
n00b


Joined: 13 Jul 2004
Posts: 60
Location: CO, USA

PostPosted: Sun Dec 17, 2006 1:12 am    Post subject: Reply with quote

xentric wrote:
Quote:
(meld:31859): GnomeUI-WARNING **: While connecting to session manager:
Authentication Rejected, reason : None of the authentication protocols specified are supported and host-based authentication failed.
This is probably causing problems when saving your changes. I probably means that meld did not get root rights and cannot save the file.

I have included sux as a dependency to the ebuild because it fixes almost all authentication problems.
So try becoming root with "sux" instead of "su" or "sudo" and try "cfg-update -u" again.

I am using sux all ready. Here's an entire console output with the sux command:
Code:
saintdev@wu-ming ~ $ sux
Password:
wu-ming saintdev # cd
wu-ming ~ # cfg-update -du
________________________________________________________________________________

cfg-update 1.8.0-r3 : Debugging mode enabled...
________________________________________________________________________________

*** Settings *******************************************************************

  mergetool     = /usr/bin/meld
  backups       = yes
  enable_stage1 = yes
  enable_stage2 = yes
  enable_stage3 = yes
  enable_stage4 = yes
  enable_stage5 = yes
  aliasfile     = /root/.bashrc
  aliascmd      = emerge_with_indexing_for_cfg-update
  portageconfig = /etc/make.conf
  progdir       = /usr/lib/cfg-update
  indexfile     = /usr/lib/cfg-update/checksum.index
  config_new    = ._cfg????_*
  rm_new        = \._cfg...._
  temp_new      = ._temp-new-cfg_*
  backup_new    = ._new-cfg_*
  restore_new   = ._cfg0000_*
  rm_old        = \._old-cfg_
  temp_old      = ._temp-old-cfg_*
  backup_old    = ._old-cfg_*
  restore_old   = *
  merged        = *.merge

*** Flags **********************************************************************

  opt_a = 0
  opt_d = 1
  opt_m = 0
  opt_p = 0
  opt_t = 
  opt_v = 0

*** Executing ******************************************************************

<root_only>
      id -u
</root_only>
<update_files>
   
    <find_protected_dirs>
          portageq config_protect
    </find_protected_dirs>
    <find_updates>
          find /etc -name '._cfg????_*'  | sort
          find /usr/kde/3.5/share/config -name '._cfg????_*'  | sort
          find /usr/share/config -name '._cfg????_*'  | sort
          find /usr/share/X11/xkb -name '._cfg????_*'  | sort
    </find_updates>
    <schedule_automatic_updates>
        <prepare_filename_for_updating>
        </prepare_filename_for_updating>
        <determine_state>
              md5sum /etc/rc.conf  | awk '{ print $1 }'
              MD5 checksum of current config file : 3efd076863bea5c8c98078a9d5c4feb3
              cat /usr/lib/cfg-update/checksum.index | grep "/etc/rc.conf " | awk '{ print $2 }'
              MD5 checksum in the checksum-index  : d822a2548ee1b0e7206e622869d2a11a
        </determine_state>
    </schedule_automatic_updates>
    <update_stage1>
        << Stage1 >> 0 files in queue, skipping...

    </update_stage1>
    <update_stage2>
        << Stage2 >> 0 files in queue, skipping...

    </update_stage2>
    <check_tool>
    </check_tool>
    <find_updates>
          find /etc -name '._cfg????_*'  | sort
          find /usr/kde/3.5/share/config -name '._cfg????_*'  | sort
          find /usr/share/config -name '._cfg????_*'  | sort
          find /usr/share/X11/xkb -name '._cfg????_*'  | sort
    </find_updates>
    <schedule_manual_updates>
        <prepare_filename_for_updating>
        </prepare_filename_for_updating>
        <determine_state>
              md5sum /etc/rc.conf  | awk '{ print $1 }'
              MD5 checksum of current config file : 3efd076863bea5c8c98078a9d5c4feb3
              cat /usr/lib/cfg-update/checksum.index | grep "/etc/rc.conf " | awk '{ print $2 }'
              MD5 checksum in the checksum-index  : d822a2548ee1b0e7206e622869d2a11a
        </determine_state>
    </schedule_manual_updates>
    <update_stage3>
        << Stage3 >> 1 files in queue, starting...

        <prepare_filename_for_updating>
        </prepare_filename_for_updating>
        <determine_state>
              md5sum /etc/rc.conf  | awk '{ print $1 }'
              MD5 checksum of current config file : 3efd076863bea5c8c98078a9d5c4feb3
              cat /usr/lib/cfg-update/checksum.index | grep "/etc/rc.conf " | awk '{ print $2 }'
              MD5 checksum in the checksum-index  : d822a2548ee1b0e7206e622869d2a11a
        </determine_state>
        <make_temp_backups>
        </make_temp_backups>
        <md5sum>
              md5sum /etc/rc.conf  | awk '{ print $1 }'
        </md5sum>
        <md5sum>
              md5sum /etc/._cfg0000_rc.conf  | awk '{ print $1 }'
        </md5sum>
        (1/1)  /etc/._cfg0000_rc.conf  [Modified File]
        <show_warning>
            * YOU ARE ABOUT TO UPDATE A MODIFIED FILE WHICH PROBABLY CONTAINS
            * CUSTOM SETTINGS. YOU ARE FORCED TO UPDATE MANUALLY!
        </show_warning>
          Found an update for /etc/rc.conf
          Press [y] - to merge the current file and the ._cfg????_* file with xxdiff
          Press [s] - to skip this update (to investigate first, and try again later)
          Press [q] - to quit cfg-update immediately
          Merge manually with file : /etc/._cfg0000_rc.conf ? [y|s|q]         <readkey>
y           
        </readkey>
        <tool_intro>
              (meld)      when done, save the merged result over the current config file by
              (meld)      right-clicking on the left pane and chosing "Save"!
        </tool_intro>
        <launch_tool>
              /usr/bin/meld /etc/rc.conf /etc/._new-cfg_rc.conf /etc/._cfg0000_rc.conf

(meld:31356): GnomeUI-WARNING **: While connecting to session manager:
Authentication Rejected, reason : None of the authentication protocols specified are supported and host-based authentication failed.
        </launch_tool>
        <tool_outro>
        </tool_outro>
          cat /etc/rc.conf.merge  | grep "^<<<<<<< \|\^||||||\|\^>>>>>>> \|\^=======$"
        <update_canceled>
            Update canceled...

        </update_canceled>
    </update_stage3>
    <update_stage4>
        << Stage4 >> 0 files in queue, skipping...

    </update_stage4>
    <update_stage5>
        << Stage5 >> 0 files in queue, skipping...

    </update_stage5>
</update_files>
<done>
    <find_updates>
          find /etc -name '._cfg????_*'  | sort
          find /usr/kde/3.5/share/config -name '._cfg????_*'  | sort
          find /usr/share/config -name '._cfg????_*'  | sort
          find /usr/share/X11/xkb -name '._cfg????_*'  | sort
    </find_updates>
1 updates remaining, run cfg-update again until all files are updated!

</done>
wu-ming ~ #

_________________
> SELECT `signature` FROM `members` WHERE `user_name`='saintdev';
0 rows returned.
Back to top
View user's profile Send private message
xentric
Guru
Guru


Joined: 16 Mar 2003
Posts: 410
Location: Netherlands

PostPosted: Mon Dec 18, 2006 11:11 pm    Post subject: Reply with quote

Try this command "xhost +localhost" as the user who started the X-server. Then followed by "su" or "sux" to become root.

If that doesn't help try becoming root with "su -" or "sux -" instead of just "su" or "sux". That should have effect on the environment variables that are loaded.

The error has got something to do with authentication of the root user. I could never put my finger on what exactly goes wrong, but I think the tricks mentioned above will fix it.
_________________
When all else fails, read the manual...
Registered Linux User #340626
Back to top
View user's profile Send private message
saintdev
n00b
n00b


Joined: 13 Jul 2004
Posts: 60
Location: CO, USA

PostPosted: Tue Dec 19, 2006 3:24 am    Post subject: Reply with quote

xentric wrote:
Try this command "xhost +localhost" as the user who started the X-server. Then followed by "su" or "sux" to become root.

If that doesn't help try becoming root with "su -" or "sux -" instead of just "su" or "sux". That should have effect on the environment variables that are loaded.

The error has got something to do with authentication of the root user. I could never put my finger on what exactly goes wrong, but I think the tricks mentioned above will fix it.

Nope, and nope:
Code:
nate@wu-ming ~ $ xhost +localhost
localhost being added to access control list
saintdev@wu-ming ~ $ sux
Password:
wu-ming saintdev # cd
wu-ming ~ # cfg-update -du
________________________________________________________________________________

cfg-update 1.8.0-r3 : Debugging mode enabled...
________________________________________________________________________________

*** Settings *******************************************************************

  mergetool     = /usr/bin/meld
  backups       = yes
  enable_stage1 = yes
  enable_stage2 = yes
  enable_stage3 = yes
  enable_stage4 = yes
  enable_stage5 = yes
  aliasfile     = /root/.bashrc
  aliascmd      = emerge_with_indexing_for_cfg-update
  portageconfig = /etc/make.conf
  progdir       = /usr/lib/cfg-update
  indexfile     = /usr/lib/cfg-update/checksum.index
  config_new    = ._cfg????_*
  rm_new        = \._cfg...._
  temp_new      = ._temp-new-cfg_*
  backup_new    = ._new-cfg_*
  restore_new   = ._cfg0000_*
  rm_old        = \._old-cfg_
  temp_old      = ._temp-old-cfg_*
  backup_old    = ._old-cfg_*
  restore_old   = *
  merged        = *.merge

*** Flags **********************************************************************

  opt_a = 0
  opt_d = 1
  opt_m = 0
  opt_p = 0
  opt_t = 
  opt_v = 0

*** Executing ******************************************************************

<root_only>
      id -u
</root_only>
<update_files>
   
    <find_protected_dirs>
          portageq config_protect
    </find_protected_dirs>
    <find_updates>
          find /etc -name '._cfg????_*'  | sort
          find /usr/kde/3.5/share/config -name '._cfg????_*'  | sort
          find /usr/share/config -name '._cfg????_*'  | sort
          find /usr/share/X11/xkb -name '._cfg????_*'  | sort
    </find_updates>
    <schedule_automatic_updates>
        <prepare_filename_for_updating>
        </prepare_filename_for_updating>
        <determine_state>
              md5sum /etc/rc.conf  | awk '{ print $1 }'
              MD5 checksum of current config file : 693ae45cbb837a2579f1cfe50fa9c12f
              cat /usr/lib/cfg-update/checksum.index | grep "/etc/rc.conf " | awk '{ print $2 }'
              MD5 checksum in the checksum-index  : d822a2548ee1b0e7206e622869d2a11a
        </determine_state>
    </schedule_automatic_updates>
    <update_stage1>
        << Stage1 >> 0 files in queue, skipping...

    </update_stage1>
    <update_stage2>
        << Stage2 >> 0 files in queue, skipping...

    </update_stage2>
    <check_tool>
    </check_tool>
    <find_updates>
          find /etc -name '._cfg????_*'  | sort
          find /usr/kde/3.5/share/config -name '._cfg????_*'  | sort
          find /usr/share/config -name '._cfg????_*'  | sort
          find /usr/share/X11/xkb -name '._cfg????_*'  | sort
    </find_updates>
    <schedule_manual_updates>
        <prepare_filename_for_updating>
        </prepare_filename_for_updating>
        <determine_state>
              md5sum /etc/rc.conf  | awk '{ print $1 }'
              MD5 checksum of current config file : 693ae45cbb837a2579f1cfe50fa9c12f
              cat /usr/lib/cfg-update/checksum.index | grep "/etc/rc.conf " | awk '{ print $2 }'
              MD5 checksum in the checksum-index  : d822a2548ee1b0e7206e622869d2a11a
        </determine_state>
    </schedule_manual_updates>
    <update_stage3>
        << Stage3 >> 1 files in queue, starting...

        <prepare_filename_for_updating>
        </prepare_filename_for_updating>
        <determine_state>
              md5sum /etc/rc.conf  | awk '{ print $1 }'
              MD5 checksum of current config file : 693ae45cbb837a2579f1cfe50fa9c12f
              cat /usr/lib/cfg-update/checksum.index | grep "/etc/rc.conf " | awk '{ print $2 }'
              MD5 checksum in the checksum-index  : d822a2548ee1b0e7206e622869d2a11a
        </determine_state>
        <make_temp_backups>
        </make_temp_backups>
        <md5sum>
              md5sum /etc/rc.conf  | awk '{ print $1 }'
        </md5sum>
        <md5sum>
              md5sum /etc/._cfg0000_rc.conf  | awk '{ print $1 }'
        </md5sum>
        (1/1)  /etc/._cfg0000_rc.conf  [Modified File]
        <show_warning>
            * YOU ARE ABOUT TO UPDATE A MODIFIED FILE WHICH PROBABLY CONTAINS
            * CUSTOM SETTINGS. YOU ARE FORCED TO UPDATE MANUALLY!
        </show_warning>
          Found an update for /etc/rc.conf
          Press [y] - to merge the current file and the ._cfg????_* file with xxdiff
          Press [s] - to skip this update (to investigate first, and try again later)
          Press [q] - to quit cfg-update immediately
          Merge manually with file : /etc/._cfg0000_rc.conf ? [y|s|q]         <readkey>
y           
        </readkey>
        <tool_intro>
              (meld)      when done, save the merged result over the current config file by
              (meld)      right-clicking on the left pane and chosing "Save"!
        </tool_intro>
        <launch_tool>
              /usr/bin/meld /etc/rc.conf /etc/._new-cfg_rc.conf /etc/._cfg0000_rc.conf

(meld:5124): GnomeUI-WARNING **: While connecting to session manager:
Authentication Rejected, reason : None of the authentication protocols specified are supported and host-based authentication failed.
        </launch_tool>
        <tool_outro>
        </tool_outro>
          cat /etc/rc.conf.merge  | grep "^<<<<<<< \|\^||||||\|\^>>>>>>> \|\^=======$"
        <update_canceled>
            Update canceled...

        </update_canceled>
    </update_stage3>
    <update_stage4>
        << Stage4 >> 0 files in queue, skipping...

    </update_stage4>
    <update_stage5>
        << Stage5 >> 0 files in queue, skipping...

    </update_stage5>
</update_files>
<done>
    <find_updates>
          find /etc -name '._cfg????_*'  | sort
          find /usr/kde/3.5/share/config -name '._cfg????_*'  | sort
          find /usr/share/config -name '._cfg????_*'  | sort
          find /usr/share/X11/xkb -name '._cfg????_*'  | sort
    </find_updates>
1 updates remaining, run cfg-update again until all files are updated!

</done>
wu-ming ~ # exit
exit

Setting xhost +localhost didn't change a thing.
Code:

saintdev@wu-ming ~ $ sux -
Password:
wu-ming ~ # cfg-update -du
________________________________________________________________________________

cfg-update 1.8.0-r3 : Debugging mode enabled...
________________________________________________________________________________

*** Settings *******************************************************************

  mergetool     = /usr/bin/meld
  backups       = yes
  enable_stage1 = yes
  enable_stage2 = yes
  enable_stage3 = yes
  enable_stage4 = yes
  enable_stage5 = yes
  aliasfile     = /root/.bashrc
  aliascmd      = emerge_with_indexing_for_cfg-update
  portageconfig = /etc/make.conf
  progdir       = /usr/lib/cfg-update
  indexfile     = /usr/lib/cfg-update/checksum.index
  config_new    = ._cfg????_*
  rm_new        = \._cfg...._
  temp_new      = ._temp-new-cfg_*
  backup_new    = ._new-cfg_*
  restore_new   = ._cfg0000_*
  rm_old        = \._old-cfg_
  temp_old      = ._temp-old-cfg_*
  backup_old    = ._old-cfg_*
  restore_old   = *
  merged        = *.merge

*** Flags **********************************************************************

  opt_a = 0
  opt_d = 1
  opt_m = 0
  opt_p = 0
  opt_t = 
  opt_v = 0

*** Executing ******************************************************************

<root_only>
      id -u
</root_only>
<update_files>
   
    <find_protected_dirs>
          portageq config_protect
    </find_protected_dirs>
    <find_updates>
          find /etc -name '._cfg????_*'  | sort
          find /usr/kde/3.5/share/config -name '._cfg????_*'  | sort
          find /usr/share/config -name '._cfg????_*'  | sort
          find /usr/share/X11/xkb -name '._cfg????_*'  | sort
    </find_updates>
    <schedule_automatic_updates>
        <prepare_filename_for_updating>
        </prepare_filename_for_updating>
        <determine_state>
              md5sum /etc/rc.conf  | awk '{ print $1 }'
              MD5 checksum of current config file : b51f74babb72402cac08286de1930e25
              cat /usr/lib/cfg-update/checksum.index | grep "/etc/rc.conf " | awk '{ print $2 }'
              MD5 checksum in the checksum-index  : d822a2548ee1b0e7206e622869d2a11a
        </determine_state>
    </schedule_automatic_updates>
    <update_stage1>
        << Stage1 >> 0 files in queue, skipping...

    </update_stage1>
    <update_stage2>
        << Stage2 >> 0 files in queue, skipping...

    </update_stage2>
    <check_tool>
    </check_tool>
    <find_updates>
          find /etc -name '._cfg????_*'  | sort
          find /usr/kde/3.5/share/config -name '._cfg????_*'  | sort
          find /usr/share/config -name '._cfg????_*'  | sort
          find /usr/share/X11/xkb -name '._cfg????_*'  | sort
    </find_updates>
    <schedule_manual_updates>
        <prepare_filename_for_updating>
        </prepare_filename_for_updating>
        <determine_state>
              md5sum /etc/rc.conf  | awk '{ print $1 }'
              MD5 checksum of current config file : b51f74babb72402cac08286de1930e25
              cat /usr/lib/cfg-update/checksum.index | grep "/etc/rc.conf " | awk '{ print $2 }'
              MD5 checksum in the checksum-index  : d822a2548ee1b0e7206e622869d2a11a
        </determine_state>
    </schedule_manual_updates>
    <update_stage3>
        << Stage3 >> 1 files in queue, starting...

        <prepare_filename_for_updating>
        </prepare_filename_for_updating>
        <determine_state>
              md5sum /etc/rc.conf  | awk '{ print $1 }'
              MD5 checksum of current config file : b51f74babb72402cac08286de1930e25
              cat /usr/lib/cfg-update/checksum.index | grep "/etc/rc.conf " | awk '{ print $2 }'
              MD5 checksum in the checksum-index  : d822a2548ee1b0e7206e622869d2a11a
        </determine_state>
        <make_temp_backups>
        </make_temp_backups>
        <md5sum>
              md5sum /etc/rc.conf  | awk '{ print $1 }'
        </md5sum>
        <md5sum>
              md5sum /etc/._cfg0000_rc.conf  | awk '{ print $1 }'
        </md5sum>
        (1/1)  /etc/._cfg0000_rc.conf  [Modified File]
        <show_warning>
            * YOU ARE ABOUT TO UPDATE A MODIFIED FILE WHICH PROBABLY CONTAINS
            * CUSTOM SETTINGS. YOU ARE FORCED TO UPDATE MANUALLY!
        </show_warning>
          Found an update for /etc/rc.conf
          Press [y] - to merge the current file and the ._cfg????_* file with xxdiff
          Press [s] - to skip this update (to investigate first, and try again later)
          Press [q] - to quit cfg-update immediately
          Merge manually with file : /etc/._cfg0000_rc.conf ? [y|s|q]         <readkey>
y           
        </readkey>
        <tool_intro>
              (meld)      when done, save the merged result over the current config file by
              (meld)      right-clicking on the left pane and chosing "Save"!
        </tool_intro>
        <launch_tool>
              /usr/bin/meld /etc/rc.conf /etc/._new-cfg_rc.conf /etc/._cfg0000_rc.conf
        </launch_tool>
        <tool_outro>
        </tool_outro>
          cat /etc/rc.conf.merge  | grep "^<<<<<<< \|\^||||||\|\^>>>>>>> \|\^=======$"
        <update_canceled>
            Update canceled...

        </update_canceled>
    </update_stage3>
    <update_stage4>
        << Stage4 >> 0 files in queue, skipping...

    </update_stage4>
    <update_stage5>
        << Stage5 >> 0 files in queue, skipping...

    </update_stage5>
</update_files>
<done>
    <find_updates>
          find /etc -name '._cfg????_*'  | sort
          find /usr/kde/3.5/share/config -name '._cfg????_*'  | sort
          find /usr/share/config -name '._cfg????_*'  | sort
          find /usr/share/X11/xkb -name '._cfg????_*'  | sort
    </find_updates>
1 updates remaining, run cfg-update again until all files are updated!

</done>

Well, that got rid of the Gnome-UI warning, but cfg-update still didn't notice that the file had changed.
_________________
> SELECT `signature` FROM `members` WHERE `user_name`='saintdev';
0 rows returned.
Back to top
View user's profile Send private message
xentric
Guru
Guru


Joined: 16 Mar 2003
Posts: 410
Location: Netherlands

PostPosted: Tue Dec 19, 2006 7:08 am    Post subject: Reply with quote

Damn... I suddenly realise why this happends.
You actually found a bug.

What probably happends is this:
Cfg-update finds the file /etc/rc.conf.merge and because that file still contains a merge conflict after the mergetool (meld in this case) was closed, it cancels the update.
That .merge file was left for either an automatic update attempt by cfg-update or by a manual attempt with another mergetool. But meld doesn't handle .merge files...

Bottomline, remove the /etc/rc.conf.merge file and disable stage2 (automatic updates) in /etc/cfg-update.conf
Meld can't handle unsuccesful automatic-updates. I'll include a fix for this in the next version.
_________________
When all else fails, read the manual...
Registered Linux User #340626
Back to top
View user's profile Send private message
saintdev
n00b
n00b


Joined: 13 Jul 2004
Posts: 60
Location: CO, USA

PostPosted: Tue Dec 19, 2006 7:36 am    Post subject: Reply with quote

xentric wrote:
Damn... I suddenly realise why this happends.
You actually found a bug.

What probably happends is this:
Cfg-update finds the file /etc/rc.conf.merge and because that file still contains a merge conflict after the mergetool (meld in this case) was closed, it cancels the update.
That .merge file was left for either an automatic update attempt by cfg-update or by a manual attempt with another mergetool. But meld doesn't handle .merge files...

Bottomline, remove the /etc/rc.conf.merge file and disable stage2 (automatic updates) in /etc/cfg-update.conf
Meld can't handle unsuccesful automatic-updates. I'll include a fix for this in the next version.

Yeah! That worked. Thanks for all the troubleshooting.
_________________
> SELECT `signature` FROM `members` WHERE `user_name`='saintdev';
0 rows returned.
Back to top
View user's profile Send private message
TooTallForPony
n00b
n00b


Joined: 13 Dec 2002
Posts: 45

PostPosted: Sun Apr 29, 2007 2:22 pm    Post subject: cfg-update, sdiff, and the r key Reply with quote

I've been using cfg-update for a while, and absolutely love it except for one thing. I typically use sdiff when maintaining remote machines, and occasionally run across files where I have to hit 'r' an awful lot to get to the end of the file (since sdiff lacks a "choose the right side for everything from here on out" key). This gets mind-numbingly dull and becomes reflexive after a while. Suddenly I find myself at the end of the file and hitting 'r' one more time before I can stop myself - thereby telling cfg-update to retry the merge and abandon everything I've just done. I've fixed this on my machines by changing instances of r to R in /usr/bin/cfg-update. Xentric, any chance I could convince you to make this change in the original?
Back to top
View user's profile Send private message
xentric
Guru
Guru


Joined: 16 Mar 2003
Posts: 410
Location: Netherlands

PostPosted: Sun Apr 29, 2007 8:15 pm    Post subject: Re: cfg-update, sdiff, and the r key Reply with quote

TooTallForPony wrote:
Suddenly I find myself at the end of the file and hitting 'r' one more time before I can stop myself - thereby telling cfg-update to retry the merge and abandon everything I've just done.
LOL, I ran into the same thing during testing of the new version!
The new version will use [u]ndo instead of [r]etry... so it's fixed already ;)
It will be released very soon!
_________________
When all else fails, read the manual...
Registered Linux User #340626
Back to top
View user's profile Send private message
matso
n00b
n00b


Joined: 06 Jun 2003
Posts: 13
Location: stockholm

PostPosted: Thu May 10, 2007 11:04 pm    Post subject: could you add support for imediff2 Reply with quote

Hi
I have been using cfg-update for a long time now.
I have always altered it to use imediff2 instead of sdiff even when i'm in X
But since a couple of versions it has become harder
And with the last one i must have missed somethin because i create a xxx.merge file but when i aswer 1 to use merged result. It still copies the new one and kills all my changes. So to make life easier. I hope you please could add this one.
imediff2 is in portage and should be invoked with imediff2 -c -o outfile infile
_________________
mats
http://www.enburk.se
Back to top
View user's profile Send private message
xentric
Guru
Guru


Joined: 16 Mar 2003
Posts: 410
Location: Netherlands

PostPosted: Wed May 16, 2007 5:51 pm    Post subject: Re: could you add support for imediff2 Reply with quote

matso wrote:
And with the last one i must have missed somethin because i create a xxx.merge file but when i aswer 1 to use merged result. It still copies the new one and kills all my changes. So to make life easier. I hope you please could add this one.
imediff2 is in portage and should be invoked with imediff2 -c -o outfile infile
You found a bug...
line 1437 calls this subroutine:
Code:
if ($key =~ /1/) { &update_replace_complete($_[0]); $key="s"; }

while it should be:
Code:
if ($key =~ /1/) { &update_merge_complete($_[0]); $key="s"; }

Took me some time to figure this one out...

I'll fix it in the new version and I'll add imediff2 so you don't have to hack the script anymore :)
Thanks for reporting this!
_________________
When all else fails, read the manual...
Registered Linux User #340626
Back to top
View user's profile Send private message
matso
n00b
n00b


Joined: 06 Jun 2003
Posts: 13
Location: stockholm

PostPosted: Wed May 23, 2007 12:31 pm    Post subject: imediff2 Reply with quote

Thank you
Now it works perfectly
_________________
mats
http://www.enburk.se
Back to top
View user's profile Send private message
turtles
Veteran
Veteran


Joined: 31 Dec 2004
Posts: 1657

PostPosted: Mon Dec 17, 2007 6:23 am    Post subject: Reply with quote

Hi there I love cfg-update. I have been using it since you recommended it to me in my helpless just hosed my system with etc-update noob post on Sat Jan 07, 2006 12:56 am.
I have a few questions; I have been getting allot of files wanting to diff that I did not modify. And or occasionaly I have dumped a modified config for a new unmodified config. Perhaps this is from using another merge tool or update tool once and the index thinks every file is hand edited.

1) Is there a feature I am missing to just skip the diff and take the new file unmodified and add it to the index as un modified. Or another work around for a batch to get back to normal? It seems to creep up on me.
2) Is there a CLI diff tool that shows the file name at the top of the screen or a patch to do this in one?
3) It looks like cfg-update can support updating servers. COOL. But how do I use it? Is the index kept on the server? Can I use a GUI merge tool locally and connect to the server?
Thanks
If these q's are answered elseware my apologies for wasting space a link would be a fine reply.
_________________
Donate to Gentoo
Back to top
View user's profile Send private message
xentric
Guru
Guru


Joined: 16 Mar 2003
Posts: 410
Location: Netherlands

PostPosted: Tue Dec 18, 2007 9:00 pm    Post subject: Reply with quote

turtles wrote:
I have been getting allot of files wanting to diff that I did not modify. And or occasionaly I have dumped a modified config for a new unmodified config. Perhaps this is from using another merge tool or update tool once and the index thinks every file is hand edited.
Paludis had a bug which caused it to write the wrong checksums to the CONTENTS files during installation of packages. So if you have updated a lot of packages with an older version of Paludis in the past, and now update such a package with Portage, there is a chance that cfg-update will wrongly think that a configfile has not been modified. I can't check right now, but I believe that I've added a special option that checks for borked CONTENTS files and offers you a list of packages to re-emerge. When done re-emerging you should run "cfg-update --force --index" to generate a fresh checksum-index... After that the problem should be gone.

If you get a chance and notice the problem again, you can also run "cfg-update -aupvd" which will do an automatic-only update in pretend mode with verbose debugging turned on. If you post the output in a private forum message I can examine what cfg-update is doing internally and what the MD5 checksums look like during the file-modification-check.

Quote:
1) Is there a feature I am missing to just skip the diff and take the new file unmodified and add it to the index as un modified. Or another work around for a batch to get back to normal? It seems to creep up on me.
Just type cfg-update --help and look for the option that will check for bad paludis installed packages. (I can't check ATM because I'm not at home)

Quote:
2) Is there a CLI diff tool that shows the file name at the top of the screen or a patch to do this in one?
Doesn't vimdiff (included in vim package) show you the filenames on the bottom?

Quote:
3) It looks like cfg-update can support updating servers. COOL. But how do I use it? Is the index kept on the server? Can I use a GUI merge tool locally and connect to the server?
Yes you can use a GUI mergetool locally to update multiple remote servers without X on them. The cfg-update program on the local computer will use the index on each remote host. So you can update from one host, but you can also use cfg-update on the remote host itself. The configfile for this functionality is /etc/cfg-update.hosts which also contains a complete HOWTO.
_________________
When all else fails, read the manual...
Registered Linux User #340626
Back to top
View user's profile Send private message
xentric
Guru
Guru


Joined: 16 Mar 2003
Posts: 410
Location: Netherlands

PostPosted: Fri Jul 11, 2008 7:34 pm    Post subject: Reply with quote

******************************************************************************

NOTE TO ALL CFG-UPDATE USERS:

After 5 years I'm finally looking for someone capable of fully adopting cfg-update as I do not have the time to properly support it anymore. I will fix all remaining bugs in week 31 and write some documentation to enable someone else to continue developing it further...
By the way, all those years I have wondered how many people are actually using cfg-update. I still have no clue!

I would really, really, really appreciate it if all you guys out there would just send a shout to xentric@zeelandnet.nl with your name or nickname and your location, just for the fun of it and to get an idea what the minimal size of the userbase is.

Drop me an e-mail on the same address if you're interested in adopting cfg-update.

Regards,

Stephan van Boven



For more details see: app-portage/cfgupdate - installation instructions

******************************************************************************
_________________
When all else fails, read the manual...
Registered Linux User #340626
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo All times are GMT
Goto page Previous  1, 2, 3, 4, 5, 6, 7, 8
Page 8 of 8

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum