View previous topic :: View next topic |
Author |
Message |
cloc3 Advocate
Joined: 13 Jan 2004 Posts: 4787 Location: http://www.gentoo-users.org/user/cloc3/
|
Posted: Sun Apr 29, 2007 4:33 pm Post subject: |
|
|
lavish wrote: | Provate a fare il link a dash invece che busybox |
in entrambi i casi il primo effetto pratico è che lo spegnimento automatico dolce con pressione del pulsante d'avvio rimane fuori uso.
troppo fastidioso, perché ne faccio uso sistematico sul laptop. _________________ vu vu vu
gentù
mi piaci tu |
|
Back to top |
|
|
lucapost Veteran
Joined: 24 Nov 2005 Posts: 1419 Location: <ud|me|ts> - Italy
|
Posted: Sun Apr 29, 2007 5:22 pm Post subject: |
|
|
lavish wrote: | Provate a fare il link a dash invece che busybox |
Anche con questo il boot è decisamente più veloce (almeno ad occhio!) e ndiswrapper compila correttamente!
ps: si accettano scommesse entro quando dovrò rimettere a posto il link per problemi di altre incompatibilità! _________________ LP |
|
Back to top |
|
|
lavish Bodhisattva
Joined: 13 Sep 2004 Posts: 4296
|
Posted: Sun Apr 29, 2007 5:24 pm Post subject: |
|
|
comio wrote: | Io dico semplicemente che la shell da chiamare sia da mettere in una variabile gestita da runscripts. Non credo che costi troppo "parametrizzare" questa cosa.
Il problema di fondo è che in generale gli script sono scritti per bash (o quanto meno sottointendono bash), bisognerebbe mettere nelle linee guida di scrittura di ipotizzare il set ridotto di sh. |
Concordo in pieno con te
Il discorso sul "sarebbe bello se..." non voleva escludere quanto affermi, anzi
Ciao! _________________ minimalblue.com | secgroup.github.io/ |
|
Back to top |
|
|
comio Advocate
Joined: 03 Jul 2003 Posts: 2191 Location: Taranto
|
Posted: Sun Apr 29, 2007 5:38 pm Post subject: |
|
|
Comunque, spulciando i sorgenti, basterebbe cambiare le intestazioni nei files *.sh in /lib64/rcscripts/sh/ (in particolare rc-help.sh).
(grep -iRn "exec[a-z]" * nei sorgenti)
Code: |
...
src/runscript.c:298: execl (RC_SVCDIR "runscript.sh", mycmd, mycmd, myarg1, myarg2,
src/runscript.c:305: execl (RC_LIBDIR "sh/runscript.sh", mycmd, mycmd, myarg1, myarg2,
src/runscript.c:881: execl (RCSCRIPT_HELP, RCSCRIPT_HELP, service, (char *) NULL);
src/runscript.c:988: execl (RCSCRIPT_HELP, RCSCRIPT_HELP, service, (char *) NULL);
src/runscript.c:1097: execl (RCSCRIPT_HELP, RCSCRIPT_HELP, service, "help", (char *) NULL);
src/runscript.c:1114: execl (RCSCRIPT_HELP, RCSCRIPT_HELP, service, (char *) NULL);
...
|
_________________ RTFM!!!!
e
http://www.comio.it
|
|
Back to top |
|
|
lavish Bodhisattva
Joined: 13 Sep 2004 Posts: 4296
|
|
Back to top |
|
|
comio Advocate
Joined: 03 Jul 2003 Posts: 2191 Location: Taranto
|
Posted: Sat May 05, 2007 10:28 am Post subject: |
|
|
lavish wrote: | E' in portage da ieri l'aplha2 |
Se è per questo ho già fatto il primo bug-report (del piffero...)
ciao _________________ RTFM!!!!
e
http://www.comio.it
|
|
Back to top |
|
|
lucapost Veteran
Joined: 24 Nov 2005 Posts: 1419 Location: <ud|me|ts> - Italy
|
Posted: Fri Nov 16, 2007 9:25 pm Post subject: |
|
|
qua la situazione mi sembra un pò ferma o sbaglio? _________________ LP |
|
Back to top |
|
|
lavish Bodhisattva
Joined: 13 Sep 2004 Posts: 4296
|
|
Back to top |
|
|
lucapost Veteran
Joined: 24 Nov 2005 Posts: 1419 Location: <ud|me|ts> - Italy
|
Posted: Sat Nov 17, 2007 9:25 am Post subject: |
|
|
lavish wrote: | Continuo a usarlo da un sacco di tempo |
su amd64 o x86? inoltre quale versione?
ed il link a /bin/sh è ancora dash? perchè a me con baselayout1 se cambio /bin/sh mi si piantano un sacco di initscript... _________________ LP |
|
Back to top |
|
|
lavish Bodhisattva
Joined: 13 Sep 2004 Posts: 4296
|
Posted: Sat Nov 17, 2007 9:44 am Post subject: |
|
|
lucapost wrote: | lavish wrote: | Continuo a usarlo da un sacco di tempo |
su amd64 o x86? inoltre quale versione?
ed il link a /bin/sh è ancora dash? perchè a me con baselayout1 se cambio /bin/sh mi si piantano un sacco di initscript... |
Sia su x86 che amd64.
Uso baselayout-2 dalla alpha1 fino ad oggi, con la rc6.
Se con baselayout-1 cambi /bin/sh per puntare a qualcosa di diverso da bash e' OVVIO che ti si piantino gli initscript _________________ minimalblue.com | secgroup.github.io/ |
|
Back to top |
|
|
crisandbea Veteran
Joined: 03 Jul 2005 Posts: 1778 Location: BOSCO (SA) ... ma domiciliato a Bologna....
|
Posted: Sat Nov 17, 2007 10:54 am Post subject: |
|
|
domanda probabilmente a cui già avete risposto, ma lo chiedo uguale ,
dopo aver emerso il baselayout2, aggiornato tutti i file che ti chiede di aggiornare emerge, bisogna fare altro??
ovvero bisogna cambiare manualmente il link simbolico da a , a ??
oppure viene fatto in automatico???
ciauz |
|
Back to top |
|
|
lucapost Veteran
Joined: 24 Nov 2005 Posts: 1419 Location: <ud|me|ts> - Italy
|
Posted: Sat Nov 17, 2007 11:01 am Post subject: |
|
|
lavish wrote: |
Se con baselayout-1 cambi /bin/sh per puntare a qualcosa di diverso da bash e' OVVIO che ti si piantino gli initscript |
la mia era un'affermazione, perdipiù confermata dall'esperienza diretta , non era una domanda.
comunque ho appena installato la rc6...ed aggiornato un pò di initscript...
devo ancora sistemare qualche cosetta...poi si vedrà.... _________________ LP |
|
Back to top |
|
|
lavish Bodhisattva
Joined: 13 Sep 2004 Posts: 4296
|
Posted: Sat Nov 17, 2007 11:55 am Post subject: |
|
|
Cambiare il link di /bin/sh a qualcosa di diverso da bash, significa rendere la propria gentoo non ufficialmente supportata.
Baselayout 2 non ha nulla a che vedere direttamente con quel link. Quello che cambia, e' solo la possibilita' di cambiare il link _________________ minimalblue.com | secgroup.github.io/ |
|
Back to top |
|
|
crisandbea Veteran
Joined: 03 Jul 2005 Posts: 1778 Location: BOSCO (SA) ... ma domiciliato a Bologna....
|
Posted: Sat Nov 17, 2007 12:03 pm Post subject: |
|
|
lavish wrote: |
Cambiare il link di /bin/sh a qualcosa di diverso da bash, significa rendere la propria gentoo non ufficialmente supportata.
Baselayout 2 non ha nulla a che vedere direttamente con quel link. Quello che cambia, e' solo la possibilita' di cambiare il link |
ok, grazie mille per la precisazione. |
|
Back to top |
|
|
lucapost Veteran
Joined: 24 Nov 2005 Posts: 1419 Location: <ud|me|ts> - Italy
|
Posted: Sat Nov 17, 2007 12:44 pm Post subject: baselayout2, /etc/conf.d/net e ppp |
|
|
Da qualche ora sto provando le brezza di baselayout2, ed ora ho un problema riguardo la configurazione dell'interfaccia dialup (tutto ok con baselayout1).
Questa è la sezione di /etc/conf.d/net riguardo alla configurazione dialup:
Code: | root@jarod
~/> grep -v "#" /etc/conf.d/net
config_ppp0="ppp"
link_ppp0="/dev/ttyUSB0"
username_ppp0='teleconomy'
password_ppp0='teleconomy'
phone_number_ppp0="7020187187"
dns_servers_ppp0="62.211.69.150"
pppd_ppp0="debug defaultroute lock 115200"
chat_ppp0=" \
'ABORT' 'BUSY' \
'ABORT' 'ERROR' \
'ABORT' 'NO ANSWER' \
'ABORT' 'NO CARRIER' \
'ABORT' 'NO DIALTONE' \
'ABORT' 'Invalid Login' \
'ABORT' 'Login incorrect' \
'TIMEOUT' '5' \
'' 'ATZ' \
'OK' 'ATDT\T' \
'TIMEOUT' '60' \
'CONNECT' '' \
'TIMEOUT' '5' \
'~--' '' \
" |
questa è la sezione riguardo alle interfaccie ppp del nuovo baselayout2 in /etc/conf.d/net.example:
Code: | #-----------------------------------------------------------------------------
# PPP
# For PPP support, emerge net-dialup/ppp
# PPP is used for most dialup connections, including ADSL.
# The older ADSL module is documented below, but you are encouraged to try
# this module first.
#
# You need to create the PPP net script yourself. Make it like so
#ln -s net.lo /etc/init.d/net.ppp0
#
# Each PPP interface requires an interface to use as a "Link"
#link_ppp0="/dev/ttyS0" # Most PPP links will use a serial port
#link_ppp0="eth0" # PPPoE requires an ethernet interface
#link_ppp0="[itf.]vpi.vci" # PPPoA requires the ATM VC's address
#link_ppp0="/dev/null" # ISDN links should have this
#link_ppp0="pty 'your_link_command'" # PPP links over ssh, rsh, etc
#
# Here you should specify what pppd plugins you want to use
# Available plugins are: pppoe, pppoa, capi, dhcpc, minconn, radius,
# radattr, radrealms and winbind
#plugins_ppp0="pppoe" # Required plugin for PPPoE
#plugins_ppp0="pppoa vc-encaps" # Required plugin for PPPoA with an option
#plugins_ppp0="capi" # Required plugin for ISDN
#
# PPP requires at least a username. You can optionally set a password here too
# If you don't, then it will use the password specified in /etc/ppp/*-secrets
# against the specified username
#username_ppp0='user'
#password_ppp0='password'
# NOTE: You can set a blank password like so
#password_ppp0=
#
# The PPP daemon has many options you can specify - although there are many
# and may seem daunting, it is recommended that you read the pppd man page
# before enabling any of them
#pppd_ppp0="
# maxfail 0 # WARNING: It's not recommended you use this
# # if you don't specify maxfail then we assume 0
# updetach # If not set, "/etc/init.d/net.ppp0 start" will return
# # immediately, without waiting the link to come up
# # for the first time.
# # Do not use it for dial-on-demand links!
# debug # Enables syslog debugging
# noauth # Do not require the peer to authenticate itself
# defaultroute # Make this PPP interface the default route
# usepeerdns # Use the DNS settings provided by PPP
#
# On demand options
# demand # Enable dial on demand
# idle 30 # Link goes down after 30 seconds of inactivity
# 10.112.112.112:10.112.112.113 # Phony IP addresses
# ipcp-accept-remote # Accept the peers idea of remote address
# ipcp-accept-local # Accept the peers idea of local address
# holdoff 3 # Wait 3 seconds after link dies before re-starting
#
# Dead peer detection
# lcp-echo-interval 15 # Send a LCP echo every 15 seconds
# lcp-echo-failure 3 # Make peer dead after 3 consective
# # echo-requests
#
# Compression options - use these to completely disable compression
# noaccomp noccp nobsdcomp nodeflate nopcomp novj novjccomp
#
# Dial-up settings
# lock # Lock serial port
# 115200 # Set the serial port baud rate
# modem crtscts # Enable hardware flow control
# 192.168.0.1:192.168.0.2 # Local and remote IP addresses
#"
#
# Dial-up PPP users need to specify at least one telephone number
#phone_number_ppp0="12345689" # Maximum 2 phone numbers are supported
# They will also need a chat script - here's a good one
#chat_ppp0=" \
# 'ABORT' 'BUSY' \
# 'ABORT' 'ERROR' \
# 'ABORT' 'NO ANSWER' \
# 'ABORT' 'NO CARRIER' \
# 'ABORT' 'NO DIALTONE' \
# 'ABORT' 'Invalid Login' \
# 'ABORT' 'Login incorrect' \
# 'TIMEOUT' '5' \
# '' 'ATZ' \
# 'OK' 'AT' # Put your modem initialization string here \
# 'OK' 'ATDT\T' \
# 'TIMEOUT' '60' \
# 'CONNECT' '' \
# 'TIMEOUT' '5' \
# '~--' '' \
#"
# If the link require extra configuration - for example wireless or
# RFC 268 bridge - we need to depend on the bridge so they get
# configured correctly.
#RC_NEED_ppp0="net.nas0"
#WARNING: if MTU of the PPP interface is less than 1500 and you use this
#machine as a router, you should add the following rule to your firewall
#
#iptables -I FORWARD 1 -p tcp --tcp-flags SYN,RST SYN -j TCPMSS --clamp-mss-to-pmtu |
e questo è l'errore:
Code: | root@jarod
~/> /etc/init.d/net.ppp0 restart
net.ppp0 | * Caching service dependencies ... [ ok ]
net.ppp0 | * Bringing up interface ppp0
net.ppp0 | * Starting pppd in ppp0 ...
net.ppp0 |eval: 8: debug: not found
net.ppp0 |eval: 10: defaultroute: not found
net.ppp0 |eval: 30: lock: not found
net.ppp0 |eval: 31: 115200: not found
net.ppp0 |eval: 34: plugin: not found
net.ppp0 | * Failed to start PPP [ !! ]
net.ppp0 | * WARNING: net.ppp0 not under our control, aborting
|
il problema sembra essere legato al fatto della nuova sintassi senza parentesi () .
Infatti quando lancio l'initscript sembra non riconoscere le opzioni che passa la variabile pppd_ppp0.
Secondo me la sintassi della mia configurazione è corretta, ma ahimè non funge.
Qualcuno sa aiutarmi?
ps: con wvdial tutto ok _________________ LP |
|
Back to top |
|
|
lavish Bodhisattva
Joined: 13 Sep 2004 Posts: 4296
|
Posted: Sat Nov 17, 2007 12:51 pm Post subject: |
|
|
Fatto il merge del thread aperto da lucapost.
Finche' baselayout-2 non esce dal periodo di testing, continuiamo qui _________________ minimalblue.com | secgroup.github.io/ |
|
Back to top |
|
|
lucapost Veteran
Joined: 24 Nov 2005 Posts: 1419 Location: <ud|me|ts> - Italy
|
Posted: Sat Nov 17, 2007 1:12 pm Post subject: |
|
|
esisterà ancora una voce così autorevole? _________________ LP |
|
Back to top |
|
|
lavish Bodhisattva
Joined: 13 Sep 2004 Posts: 4296
|
Posted: Sat Nov 17, 2007 1:18 pm Post subject: |
|
|
lucapost wrote: | esisterà ancora una voce così autorevole? |
Si' visto che, mal che vada, continuera' comunque a svilupparlo esternamente _________________ minimalblue.com | secgroup.github.io/ |
|
Back to top |
|
|
crisandbea Veteran
Joined: 03 Jul 2005 Posts: 1778 Location: BOSCO (SA) ... ma domiciliato a Bologna....
|
Posted: Mon Nov 19, 2007 7:15 am Post subject: |
|
|
con il baselayout2, come si deve configurare il file in modo tale che dandogli yes alla seguente opzione non aspetti che il dhcpcd su eth0 vada in timeout???? |
|
Back to top |
|
|
lucapost Veteran
Joined: 24 Nov 2005 Posts: 1419 Location: <ud|me|ts> - Italy
|
Posted: Mon Nov 19, 2007 9:39 am Post subject: |
|
|
crisandbea wrote: | con il baselayout2, come si deve configurare il file in modo tale che dandogli yes alla seguente opzione non aspetti che il dhcpcd su eth0 vada in timeout???? |
Code: | # Some people want a finer grain over hotplug/coldplug. RC_PLUG_SERVICES is a
# list of services that are matched in order, either allowing or not. By
# default we allow services through as RC_COLDPLUG/RC_HOTPLUG has to be yes
# anyway.
# Example - RC_PLUG_SERVICES="net.wlan !net.*"
# This allows net.wlan and any service not matching net.* to be plugged.
RC_PLUG_SERVICES="!*" |
dovrebbere essere questa la voce. _________________ LP |
|
Back to top |
|
|
LastHope Apprentice
Joined: 11 May 2005 Posts: 237 Location: Mordor
|
Posted: Mon Nov 19, 2007 11:21 am Post subject: |
|
|
crisandbea wrote: | con il baselayout2, come si deve configurare il file in modo tale che dandogli yes alla seguente opzione non aspetti che il dhcpcd su eth0 vada in timeout???? |
OT: io per non aspettare il timeout sul DHCP al boot, utilizzo il fantastico netplug:
Code: | dani@dani_lap ~/tesiLevner/Latex $ eix netplug
[I] sys-apps/netplug
Available versions: 1.2.9-r2 1.2.9-r3
Installed versions: 1.2.9-r3(14:24:24 09/14/07)
Homepage: http://www.red-bean.com/~bos/
Description: Brings up/down ethernet ports automatically with cable detection
|
|
|
Back to top |
|
|
SilverXXX l33t
Joined: 18 Sep 2004 Posts: 885
|
Posted: Mon Nov 19, 2007 1:30 pm Post subject: |
|
|
Anche se è da un pò che non posto continuo a uasre gentoo come sempre (è troppo più semplice da usare, una volta che si impara) e volevo sapere se qualcuno ha fatto prove con init-ng e baselayout2 sulla stessa macchina. _________________ about:mozilla |
|
Back to top |
|
|
xdarma l33t
Joined: 08 Dec 2003 Posts: 719 Location: tra veneto e friuli (italy)
|
Posted: Tue Nov 20, 2007 9:54 pm Post subject: |
|
|
Mi aggiungo alla lista dei curiosi.
Se poi riusciste a "misurare" le prestazioni dei sistemi al boot, per esempio con bootchart, credo fareste un favore a molti.
TIA _________________ proud user of faKeDE-4.7.3 -> back to windowmaker -> moved to LXQt |
|
Back to top |
|
|
riverdragon Veteran
Joined: 14 Sep 2006 Posts: 1269 Location: Verona
|
Posted: Wed Nov 21, 2007 8:23 am Post subject: |
|
|
Io ho guadagnato circa cinque secondi, misurazione spannometrica, da grub al prompt testuale; da 28 a 23 secondi. Con un disco a 7200 rpm probabilmente il miglioramento sarebbe maggiore. |
|
Back to top |
|
|
lucapost Veteran
Joined: 24 Nov 2005 Posts: 1419 Location: <ud|me|ts> - Italy
|
Posted: Sat Dec 01, 2007 10:30 am Post subject: |
|
|
Stavo provando a smanettare ancora un un con le shell, ho visto che con il link /bin/sh a /bin/dash mi falliscono un pò di compilazioni (ndiswrapper, ecc), oltre a qualche warning per la sintassi legata a bash di /etc/init.d/cpufreqd:
Code: | #!/sbin/runscript
# Copyright 1999-2006 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/sys-power/cpufreqd/files/cpufreqd-2.1.1-init.d,v 1.1 2006/07/04 16:34:49 brix Exp $
CONFIGFILE=/etc/cpufreqd.conf
depend() {
need localmount
use logger lm_sensors
}
checkconfig() {
if[b] [[ ! -f ${CONFIGFILE} ]]; then
eerror "Configuration file ${CONFIGFILE} not found"
return 1
fi
if [[ ! -e /proc/cpufreq ]] && [[ ! -e /sys/devices/system/cpu/cpu0/cpufreq ]]; then
eerror "cpufreqd requires the kernel to be configured with CONFIG_CPU_FREQ"
return 1
fi
}
start() {
checkconfig || return 1
ebegin "Starting CPU Frequency Daemon"
start-stop-daemon --start --exec /usr/sbin/cpufreqd -- \
-f ${CONFIGFILE}
eend ${?}
}
stop() {
ebegin "Stopping CPU Frequency Daemon"
start-stop-daemon --stop --exec /usr/sbin/cpufreqd
eend ${?}
} |
e quindi l'errore
Code: | ~/> /etc/init.d/cpufreqd restart
cpufreqd | * Caching service dependencies ... [ ok ]
cpufreqd | * Stopping CPU Frequency Daemon ... [ ok ]
cpufreqd |/lib64/rc/sh/runscript.sh: 91: [[: not found
cpufreqd |/lib64/rc/sh/runscript.sh: 91: [[: not found
cpufreqd | * Starting CPU Frequency Daemon ... |
da qui deduco che a dash non gli piace la sintassi con la doppia quadra sui condizionali..., ma comunque non è grave, l'errore per ora lo trovo solo in questo script.
Comunque sarebbe figo che gli sviluppatori dei vari initscript uniformassero un pò meglio la sintassi per rendere compatibili altre shell.
Ora, per quel che mi riguarda, a me interessa solo che gli initscript utilizzino /bin/dash, ovviamente per velocizzare i runlevel di boot e default.
Quindi sto pensando di modificare la prima riga di /lib64/rc/sh/runscript.sh, cioè al posto di
metterci
Secondo me è un'ottimo compromesso, che ne pensate? _________________ LP |
|
Back to top |
|
|
|