Forums

Skip to content

Advanced search
  • Quick links
    • Unanswered topics
    • Active topics
    • Search
  • FAQ
  • Login
  • Register
  • Board index Assistance Portage & Programming
  • Search

dispatch-conf

Problems with emerge or ebuilds? Have a basic programming question about C, PHP, Perl, BASH or something else?
Post Reply
Advanced search
49 posts
  • Previous
  • 1
  • 2
Author
Message
nihilo
Apprentice
Apprentice
User avatar
Posts: 168
Joined: Tue Nov 05, 2002 7:06 am
Location: berkeley, ca, usa
Contact:
Contact nihilo
Website

another diff tip

  • Quote

Post by nihilo » Wed Nov 10, 2004 5:24 am

I've used tkdiffb (a very nice gui diff tool that is part of the tkcvs package) since the etc-update days, and am very happy with it. It works with dispatch-conf too by setting the following in /etc/dispatch-conf.conf:

Code: Select all

diff="tkdiff %s %s"
The equivalent etc-update setting is:

Code: Select all

diff_command="tkdiff %file1 %file2"
If anybody knows how to get dispatch-conf to (A) skip binary files (or automatically use the new version), and (B) use tkdiff for merging files as well, I'd be in heaven.
Top
rhill
Retired Dev
Retired Dev
User avatar
Posts: 1629
Joined: Fri Oct 22, 2004 9:58 am
Location: sk.ca

  • Quote

Post by rhill » Wed Nov 10, 2004 5:48 am

Duty wrote:I get this error trying to run dispatch-conf:

Code: Select all

Traceback (most recent call last):
  File "/usr/sbin/dispatch-conf", line 309, in ?
    d.grind (portage.settings ['CONFIG_PROTECT'])
  File "/usr/sbin/dispatch-conf", line 145, in grind
    confs = filter (f, confs)
  File "/usr/sbin/dispatch-conf", line 135, in f
    self.replace(newconf, conf['current'])
  File "/usr/sbin/dispatch-conf", line 222, in replace
    os.system((DIFF_CONTENTS % (curconf, newconf)) + '>>' + self.config["log-file"])
AttributeError: dispatch instance has no attribute 'config'
Anyone have an idea?
yep. this was a bug in the last portage update that has been fixed. re-emerge portage and it should start working again. there's a bugzilla number for it but i'm way too lazy tonite to look it up. :wink:
Top
rhill
Retired Dev
Retired Dev
User avatar
Posts: 1629
Joined: Fri Oct 22, 2004 9:58 am
Location: sk.ca

  • Quote

Post by rhill » Wed Nov 10, 2004 5:49 am

nihilo:
robmoss wrote:Oh, and don't let dispatch-conf try to diff binary files (that's the -a flag in your diff line in dispatch-conf.conf). Take that flag out! Otherwise you'll get all sorts of interesting bugs showing up...
is that how you mean or was it something else? i haven't used tkdiffb.
Top
nihilo
Apprentice
Apprentice
User avatar
Posts: 168
Joined: Tue Nov 05, 2002 7:06 am
Location: berkeley, ca, usa
Contact:
Contact nihilo
Website

  • Quote

Post by nihilo » Wed Nov 10, 2004 7:03 am

dirtyepic wrote:nihilo:
robmoss wrote:Oh, and don't let dispatch-conf try to diff binary files (that's the -a flag in your diff line in dispatch-conf.conf). Take that flag out! Otherwise you'll get all sorts of interesting bugs showing up...
is that how you mean or was it something else? i haven't used tkdiffb.
Thanks for the help, but that applies to the standard diff executable and not to the tkdiff program (which doesn't have a man page either :()...
Top
Light
n00b
n00b
Posts: 21
Joined: Tue Jun 15, 2004 6:32 am
Location: Netherlands

  • Quote

Post by Light » Thu Nov 11, 2004 11:48 am

dirtyepic wrote:
Duty wrote:I get this error trying to run dispatch-conf:

Code: Select all

Traceback (most recent call last):
  File "/usr/sbin/dispatch-conf", line 309, in ?
    d.grind (portage.settings ['CONFIG_PROTECT'])
  File "/usr/sbin/dispatch-conf", line 145, in grind
    confs = filter (f, confs)
  File "/usr/sbin/dispatch-conf", line 135, in f
    self.replace(newconf, conf['current'])
  File "/usr/sbin/dispatch-conf", line 222, in replace
    os.system((DIFF_CONTENTS % (curconf, newconf)) + '>>' + self.config["log-file"])
AttributeError: dispatch instance has no attribute 'config'
Anyone have an idea?
yep. this was a bug in the last portage update that has been fixed. re-emerge portage and it should start working again. there's a bugzilla number for it but i'm way too lazy tonite to look it up. :wink:
I would have expected a new release version to solve this, but that doesn't seem to be the case. I'm quite sure I have the latest version (the last few times I did "emerge sync" it didn't give me a newer version) and I also have this problem. The last time I did "emerge sync" was some 12 hours ago.

But I guess I would have to do "emerge portage" to solve this? I might have to give that a try then :)
Top
markandrew
Apprentice
Apprentice
Posts: 176
Joined: Wed Feb 04, 2004 10:12 am
Location: Manchester, UK

  • Quote

Post by markandrew » Thu Nov 11, 2004 2:50 pm

i occasionally have dispatch-conf leaving crap in some config files, eg

Code: Select all

# Disables the magic-sysrq key
#kernel.sysrq = 0
<<<<<<< /etc/sysctl.conf

# set kernel to re-use RAM rather than swap
vm.swappiness = 25
=======
# When the kernel panics, automatically reboot in 3 seconds
#kernel.panic = 3
# Allow for more PIDs (cool factor!); may break some programs
#kernel.pid_max = 999999

# TCP Port for lock manager
#sys.fs.nfs.nlm_tcpport = 0
# UDP Port for lock manager
#sys.fs.nfs.nlm_udpport = 0
>>>>>>> /etc/._cfg0000_sysctl.conf
                                       
in /etc/sysctl.conf - note the lines starting with >>>>> and <<<<

this seems to happen at random and really screws things up; i only notice when erorrs start cascading down the screen at boot, although now i check for it each time i update baselayout (which for some reason is when it all seems to happen). anyone know what causes it?
Top
mallchin
l33t
l33t
User avatar
Posts: 655
Joined: Tue Jan 21, 2003 9:59 pm
Location: United Kingdom
Contact:
Contact mallchin
Website

  • Quote

Post by mallchin » Thu Nov 11, 2004 2:58 pm

Well, dispatch-conf has started to fsck up my config files, mearly running it is enough to break things...

The diff variants (stored in rcs) are making there way into /etc and, naturally, Gentoo spits feathers when it boots....

Has anyone else had this?

*edit*

Just seen your post markandrew, same problem here.

This kinda sux; I use Gentoo in a production enviroment and had I have been using dispatch-conf (as planned) it would have caused me a load of grief....

How come things aren't tested :(
6700 @ 2.66GHz, 4Gb RAM, 2 x 500Gb, 8800 GTX, PhysX, X-Fi, 24" Widescreen, Tux mascot
Top
squeegy
Guru
Guru
User avatar
Posts: 321
Joined: Sat Mar 13, 2004 11:46 pm
Location: Cincinnati, OH

  • Quote

Post by squeegy » Thu Nov 11, 2004 5:26 pm

mallchin wrote:Well, dispatch-conf has started to fsck up my config files, mearly running it is enough to break things...

The diff variants (stored in rcs) are making there way into /etc and, naturally, Gentoo spits feathers when it boots....

Has anyone else had this?

*edit*

Just seen your post markandrew, same problem here.

This kinda sux; I use Gentoo in a production enviroment and had I have been using dispatch-conf (as planned) it would have caused me a load of grief....

How come things aren't tested :(
You answered your own question you're using Gentoo, a noncommercial distribution of Linux, and expecting commercial level perfection. There are many threads on this board that discuss why Gentoo is not great for a production environment. IMO dispatch-conf works very well, I've personally never had any problems.
Top
nihilo
Apprentice
Apprentice
User avatar
Posts: 168
Joined: Tue Nov 05, 2002 7:06 am
Location: berkeley, ca, usa
Contact:
Contact nihilo
Website

  • Quote

Post by nihilo » Thu Nov 11, 2004 5:45 pm

Light wrote:
dirtyepic wrote:
Duty wrote:I get this error trying to run dispatch-conf:

Code: Select all

Traceback (most recent call last):
  File "/usr/sbin/dispatch-conf", line 309, in ?
    d.grind (portage.settings ['CONFIG_PROTECT'])
  File "/usr/sbin/dispatch-conf", line 145, in grind
    confs = filter (f, confs)
  File "/usr/sbin/dispatch-conf", line 135, in f
    self.replace(newconf, conf['current'])
  File "/usr/sbin/dispatch-conf", line 222, in replace
    os.system((DIFF_CONTENTS % (curconf, newconf)) + '>>' + self.config["log-file"])
AttributeError: dispatch instance has no attribute 'config'
Anyone have an idea?
yep. this was a bug in the last portage update that has been fixed. re-emerge portage and it should start working again. there's a bugzilla number for it but i'm way too lazy tonite to look it up. :wink:
I would have expected a new release version to solve this, but that doesn't seem to be the case. I'm quite sure I have the latest version (the last few times I did "emerge sync" it didn't give me a newer version) and I also have this problem. The last time I did "emerge sync" was some 12 hours ago.

But I guess I would have to do "emerge portage" to solve this? I might have to give that a try then :)
If you still haven't solved this, the solution is to change self.config to self.options on line 222 of the dispatch-conf script, which is the last line quoted in that stack trace you posted ("os.system((DIFF_CONTENTS .... ))").

hth...
Top
Light
n00b
n00b
Posts: 21
Joined: Tue Jun 15, 2004 6:32 am
Location: Netherlands

  • Quote

Post by Light » Thu Nov 11, 2004 7:59 pm

nihilo wrote:
If you still haven't solved this, the solution is to change self.config to self.options on line 222 of the dispatch-conf script, which is the last line quoted in that stack trace you posted ("os.system((DIFF_CONTENTS .... ))").

hth...
Thanks :) That seems to have solved the problems for me. I didn't rebuild portage though, this edit is easier.
Top
chrisstankevitz
Guru
Guru
Posts: 472
Joined: Sun Dec 14, 2003 10:31 pm
Location: Santa Barbara, CA, USA

  • Quote

Post by chrisstankevitz » Tue Nov 30, 2004 4:22 pm

dirtyepic wrote:
Duty wrote:I get this error trying to run dispatch-conf:

Code: Select all

Traceback (most recent call last):
  File "/usr/sbin/dispatch-conf", line 309, in ?
    d.grind (portage.settings ['CONFIG_PROTECT'])
  File "/usr/sbin/dispatch-conf", line 145, in grind
    confs = filter (f, confs)
  File "/usr/sbin/dispatch-conf", line 135, in f
    self.replace(newconf, conf['current'])
  File "/usr/sbin/dispatch-conf", line 222, in replace
    os.system((DIFF_CONTENTS % (curconf, newconf)) + '>>' + self.config["log-file"])
AttributeError: dispatch instance has no attribute 'config'
Anyone have an idea?
yep. this was a bug in the last portage update that has been fixed. re-emerge portage and it should start working again. there's a bugzilla number for it but i'm way too lazy tonite to look it up. :wink:
Why was it fixed in such a way as to require a remerge?

Couldn't the gentoo developers fix it in such a way that regular "emerge -Dauv world" updating would automatically fix it?

Just curious,

Chris
Top
agnitio
Tux's lil' helper
Tux's lil' helper
Posts: 136
Joined: Sat Apr 17, 2004 9:02 am

  • Quote

Post by agnitio » Fri Dec 03, 2004 11:08 am

I am also having problems with dispatch-conf ouputting garbage into config-files. Is there any workaround for this?
Top
mphilips
n00b
n00b
User avatar
Posts: 49
Joined: Tue Sep 09, 2003 11:05 pm

dispatch-conf edit feature

  • Quote

Post by mphilips » Sun Jan 09, 2005 8:22 pm

When I press "e" to open the newly merged file in my preferred editor I get:

Code: Select all

Traceback (most recent call last):
  File "/usr/sbin//dispatch-conf", line 309, in ?
    d.grind (portage.settings ['CONFIG_PROTECT'])
  File "/usr/sbin//dispatch-conf", line 200, in grind
    os.system(os.environ['EDITOR'] + ' ' + newconf)
  File "/usr/lib/python2.3/UserDict.py", line 19, in __getitem__
    def __getitem__(self, key): return self.data[key]
KeyError: 'EDITOR'
Top
rhill
Retired Dev
Retired Dev
User avatar
Posts: 1629
Joined: Fri Oct 22, 2004 9:58 am
Location: sk.ca

  • Quote

Post by rhill » Sun Jan 09, 2005 11:26 pm

what does

Code: Select all

echo $EDITOR
turn up and can you run that from the command line?
by design, by neglect
for a fact or just for effect
Top
mphilips
n00b
n00b
User avatar
Posts: 49
Joined: Tue Sep 09, 2003 11:05 pm

  • Quote

Post by mphilips » Sun Jan 09, 2005 11:55 pm

dirtyepic wrote:what does

Code: Select all

echo $EDITOR
turn up and can you run that from the command line?

Code: Select all

/bin/nano
and yes
Top
gmtl3
Tux's lil' helper
Tux's lil' helper
Posts: 135
Joined: Sat Jan 03, 2004 5:08 am

  • Quote

Post by gmtl3 » Thu Jan 13, 2005 3:36 am

According to the make.conf man page, I can set CONFIG_PROTECT_MASK to a space delimeted list of directories that you want to exempt from config file protection. Here's mine:

Code: Select all

CONFIG_PROTECT_MASK="/usr/X11R6"
So, how come dispatch-conf is still asking me about updating files under /usr/X11R6/lib/*?
Top
mphilips
n00b
n00b
User avatar
Posts: 49
Joined: Tue Sep 09, 2003 11:05 pm

me too

  • Quote

Post by mphilips » Thu Jan 13, 2005 5:31 am

dhurt wrote:one thing I miss from etc-update is the list of files that need to be modified. I know which files on my system I have modified, and so I would change those and then just scan the list of files one more time and then have etc-update nuke/update all the rest of the files.
I agree, it should at least be an menu option.
Top
gmtl3
Tux's lil' helper
Tux's lil' helper
Posts: 135
Joined: Sat Jan 03, 2004 5:08 am

  • Quote

Post by gmtl3 » Sun Jan 16, 2005 12:13 am

gmtl3 wrote:According to the make.conf man page, I can set CONFIG_PROTECT_MASK to a space delimeted list of directories that you want to exempt from config file protection. Here's mine:

Code: Select all

CONFIG_PROTECT_MASK="/usr/X11R6"
So, how come dispatch-conf is still asking me about updating files under /usr/X11R6/lib/*?
I stole the first bit of code from dispatch-conf and modified it like so

Code: Select all

#!/usr/bin/python -O

#
# dispatch-conf-debug-CONFIG_PROTECT_MASK
#       - figure out why dispatch-conf ingores CONFIG_PROTECT_MASK
#
#  Jeremy Wohl (http://igmus.org)
#
#

from stat import *
from random import *
import os, shutil, sys, string, re, commands, atexit
sys.path = ["/usr/lib/portage/pym"]+sys.path

import portage, dispatch_conf

print portage.settings ['CONFIG_PROTECT_MASK']
Here's the output:

Code: Select all

$ ./cfgProtMaskTest
/etc/gconf /etc/terminfo /usr/X11R6/lib /etc/env.d
$
"/usr/X11R6/lib" is what I had CONFIG_PROTECT_MASK set to in /etc/make.conf. Still not sure why the config files under that subdir weren't auto updated when I ran dispatch-conf.
Top
tecknojunky
Veteran
Veteran
User avatar
Posts: 1937
Joined: Sat Oct 19, 2002 6:50 am
Location: Montréal
Contact:
Contact tecknojunky
Website

  • Quote

Post by tecknojunky » Sat Jan 29, 2005 1:27 pm

Stiffler wrote:Can someone please explain the differences between etc-update and dispatch-conf? I've hosed my box using etc-update and I really don't want to do that again. The best way to not screw something up is understanding how it works...
Yup. You can hose your system just as easyly with dispatch-conf.
(7 of 9) Installing star-trek/species-8.4.7.2::talax.
Top
vanten
n00b
n00b
User avatar
Posts: 44
Joined: Sun Jan 08, 2006 7:10 pm
Location: Sweden

  • Quote

Post by vanten » Wed Mar 01, 2006 10:12 pm

BTW:
allucid wrote:Now edit /etc/dispatc-conf.conf to your liking.
Should be /etc/dispatch-conf.conf
But perhaps everyone allready seen that
.: GNU/Linux :: Gentoo :: Fluxbox :.
.: BSD :: OpenBSD :: Fluxbox :.
Top
mallchin
l33t
l33t
User avatar
Posts: 655
Joined: Tue Jan 21, 2003 9:59 pm
Location: United Kingdom
Contact:
Contact mallchin
Website

  • Quote

Post by mallchin » Thu Mar 02, 2006 2:41 pm

Nothing like dragging up an old topic :wink:
6700 @ 2.66GHz, 4Gb RAM, 2 x 500Gb, 8800 GTX, PhysX, X-Fi, 24" Widescreen, Tux mascot
Top
bvrom
n00b
n00b
Posts: 2
Joined: Fri Aug 25, 2006 2:01 pm

Can I remove config-archive?

  • Quote

Post by bvrom » Sat Aug 26, 2006 11:39 am

My / (root) partition is getting too full and I'm seeing where I can delete some data. My /etc/config-archive (dispatche-conf's archive that is) has become quite big. Is it safe to remove the contents of this directory? I know my current config files are OK and I have made backups before, so there is currently no need to revert to older /etc files. The manpage and wiki page don't seem to give any info on this.
Top
bmichaelsen
Veteran
Veteran
User avatar
Posts: 1277
Joined: Sun Nov 17, 2002 2:38 am
Location: Hamburg, Germany

  • Quote

Post by bmichaelsen » Sun Nov 19, 2006 7:29 pm

00tux wrote:I'm totally confused by the output that I am given. So if I know that I have edited the config file what do I do. The - and + everywhere are confuzling the newby.
Stiffler wrote:Can someone please explain the differences between etc-update and dispatch-conf? I've hosed my box using etc-update and I really don't want to do that again. The best way to not screw something up is understanding how it works...
Yup. You can hose your system just as easyly with dispatch-conf.[/quote]
Maybe you guys want to have a look at etc-proposals, it has a built-in help system and although its pretty new, its already in the gentoo sunrise overlay.
Last edited by bmichaelsen on Sun Nov 19, 2006 9:05 pm, edited 1 time in total.
Top
bmichaelsen
Veteran
Veteran
User avatar
Posts: 1277
Joined: Sun Nov 17, 2002 2:38 am
Location: Hamburg, Germany

Re: Can I remove config-archive?

  • Quote

Post by bmichaelsen » Sun Nov 19, 2006 9:04 pm

bvrom wrote:My / (root) partition is getting too full and I'm seeing where I can delete some data. My /etc/config-archive (dispatche-conf's archive that is) has become quite big. Is it safe to remove the contents of this directory? I know my current config files are OK and I have made backups before, so there is currently no need to revert to older /etc files. The manpage and wiki page don't seem to give any info on this.
Its save.
Top
Post Reply

49 posts
  • Previous
  • 1
  • 2

Return to “Portage & Programming”

Jump to
  • Assistance
  • ↳   News & Announcements
  • ↳   Frequently Asked Questions
  • ↳   Installing Gentoo
  • ↳   Multimedia
  • ↳   Desktop Environments
  • ↳   Networking & Security
  • ↳   Kernel & Hardware
  • ↳   Portage & Programming
  • ↳   Gamers & Players
  • ↳   Other Things Gentoo
  • ↳   Unsupported Software
  • Discussion & Documentation
  • ↳   Documentation, Tips & Tricks
  • ↳   Gentoo Chat
  • ↳   Gentoo Forums Feedback
  • ↳   Duplicate Threads
  • International Gentoo Users
  • ↳   中文 (Chinese)
  • ↳   Dutch
  • ↳   Finnish
  • ↳   French
  • ↳   Deutsches Forum (German)
  • ↳   Diskussionsforum
  • ↳   Deutsche Dokumentation
  • ↳   Greek
  • ↳   Forum italiano (Italian)
  • ↳   Forum di discussione italiano
  • ↳   Risorse italiane (documentazione e tools)
  • ↳   Polskie forum (Polish)
  • ↳   Instalacja i sprzęt
  • ↳   Polish OTW
  • ↳   Portuguese
  • ↳   Documentação, Ferramentas e Dicas
  • ↳   Russian
  • ↳   Scandinavian
  • ↳   Spanish
  • ↳   Other Languages
  • Architectures & Platforms
  • ↳   Gentoo on ARM
  • ↳   Gentoo on PPC
  • ↳   Gentoo on Sparc
  • ↳   Gentoo on Alternative Architectures
  • ↳   Gentoo on AMD64
  • ↳   Gentoo for Mac OS X (Portage for Mac OS X)
  • Board index
  • All times are UTC
  • Delete cookies

© 2001–2026 Gentoo Foundation, Inc.

Powered by phpBB® Forum Software © phpBB Limited

Privacy Policy

 

 

magic