» »

net in gentoo

net in gentoo

bombacina ::

Zivjo!

Imammali problem.

V live CD-ju je net deloval (adsl) v root sistemu pa ukaz adsl-setup sploh ne prime, kaj je narobe.

Hvala

moj_nick ::

Ko si končal inštalacijo, nisi naredil USE="-X" emerge rp-pppoe, ki bi ti inštaliral clienta za adsl.

Vrni se v LiveCD, naredi

adsl-setup
adsl-start
mkdir /mnt/gentoo
mount /dev/ROOT /mnt/gentoo
chroot /mnt/gentoo /bin/bash
USE="-X" emerge rp-pppoe
exit
cd /
umount /mnt/gentoo
reboot
110111001001010001010000

bombacina ::

Ok hvala sedaj dela.

Samo se tole, kako pa naredim, da bo ta racunalnik glavni, drugi pa bo preko tega v mrezi, kaj morem porihtati!

Hvala

moj_nick ::

Samba za šeranje direktorijev z Windows uporabniki, za internet iptables: 1 in 2
110111001001010001010000

Poldi112 ::

Jaz sem si danes naredil nov velik problem. Pomotoma sem pobrisal net.ppp0. Sedaj mi ne najde vec ppp0. Ce naerdim ln -s na eth0, kot sem z eth1, ne dela. Sem unmergal rp-pppoe in se enkrat instaliral, isto. Takrat mislim da mi je rp-pppoe instaliral ppp0, sedaj pa noce. Adsl-start mi rece da pac ni ppp0. Ifconfig ga ne najde in noce spraviti "up".
Kaksna ideja, kako naj dobim nazaj ppp0.

moj_nick ::

emerge ppp bi mogoče delal

Lahko bi pa tudi povedal točno pot file-a in bi ga kdo paste-al sem.
110111001001010001010000

Poldi112 ::

Sem naredil emerge ppp, zdaj imam net.ppp0, ampak ni ok.
adsl-status
adsl-status: Link is attached to ppp0, but ppp0 is down

ifconfig ppp0 up
ppp0: unknown interface: No such device.


File je /etc/init.d/net.ppp0

Brane2 ::

Kaj pa, če je reemerganje rp-pppoeja povozilo tvoje nastavitve accounta ?

Sedaj se ti očitno ppp link ne vzpostavi, verjetno zato, ker te druga stran ne spusti gor.


Probaj še enkrat nastavit stvari z adsl-setup

Zgodovina sprememb…

  • spremenil: Brane2 ()

Poldi112 ::

ne pomaga. Ze prej sem odinstaliral pppoe in iptables, nazaj instaliral pppoe, instaliral ppp, odinstaliral vse, instaliral ppp nato pppoe, nic.
adsl-setup si je zapomnil nastavitve. Vsaj username. Sem ga zalaufal, ni slo. Sem rocno povozil config files v /etc/ppp s starimi, ki so delali, pa tudi ne gre. Precej debilno mi je uspelo spustiti en file backupirat.

BigWhale ::

# tail /var/log/message
# tail /var/log/...

pa malo povej kaj pise v logih...

Kaj pa ce pozenes

# /etc/init.d/net.ppp0 start

?

moj_nick ::

Evo

 #!/sbin/runscript
# Copyright 1999-2003 Gentoo Technologies, Inc.
# Distributed under the terms of the GNU General Public License v2
# Author:  Martin Schlemmer <azarah@gentoo.org>
# Credits:  To all those I got ideas from :)
#
# $Header: /home/cvsroot/gentoo-x86/net-dialup/ppp/files/net.ppp0,v 1.3 2003/09/06 11:11:27 seemant Exp $

# NB: Config is in /etc/conf.d/net.$IFACE


# Misc internal variables
CMD_LINE=""
FUNCT="$2"
TEMPLATEDIR="/etc/ppp"

checkconfig() {

        if [ ! -x "$(which pppd)" -o ! -x "$(which chat)" ]
        then
                eerror "pppd and chat needs to be installed"
                return 1
        fi

        if [ -e "/var/run/ppp-${IFACE}.pid" -o -e "/var/run/${IFACE}.pid" ] && \
           [ "${FUNCT}" = "start" ]
        then
                eerror "ppp0 is already up"
                return 1
        fi
}

start() {

        checkconfig || return 1

        setup_cmd_line
        setup_cfg_files

        ebegin "Bringing ${IFACE} up"
        if [ -x "$(which pppd)" ]
        then

                if [ "${DEFROUTE}" = "yes" ]
                then
                        [ -n "$(/sbin/route | egrep 'default')" ] && route del default
                fi
                # Added hide-password here, can't be too sure...
                /usr/sbin/pppd ${CMD_LINE} ${MODEMPORT} ${LINESPEED} \
                        ipparam ${IFACE} linkname ${IFACE} call ${PEER} \
                        noauth ${PPPOPTIONS} hide-password
        fi
        eend
}

stop() {

        checkconfig || return 1

        ebegin "Bringing ${IFACE} down"
        if [ -x "$(which ifconfig)" ]
        then

                if [ -z "$(/sbin/ifconfig | egrep "${IFACE}")" ]
                then
                        ewarn "Interface seems to be down already"
                        # We should return 0 here, else svc_stop() will not remove
                        # the 'started' symlink ...
                        return 0
                fi

#               /sbin/ifconfig ${IFACE} down
                if [ -e /var/run/ppp-${IFACE}.pid ]
                then
                        kill $(egrep -v "${IFACE}" /var/run/ppp-${IFACE}.pid)

                elif [ -e /var/run/${IFACE}.pid ]
                then
                        kill $(egrep -v "${IFACE}" /var/run/${IFACE}.pid)
                fi
        fi
        eend
}

setup_cmd_line() {

        CMD_LINE="lock"

        if [ "${DEBUG}" = "yes" ]
        then
                CMD_LINE="${CMD_LINE} debug"
        fi

        if [ "${PERSIST}" = "yes" ]
        then
                CMD_LINE="${CMD_LINE} persist holdoff ${RETRYTIMEOUT}"
        fi

        if [ "${DEFROUTE}" = "yes" ]
        then
                CMD_LINE="${CMD_LINE} defaultroute"
        fi

        if [ "${HARDFLOWCTL}" = "yes" ]
        then
                CMD_LINE="${CMD_LINE} modem crtscts"
        fi

        if [ "${ESCAPECHARS}" = "yes" ]
        then
                CMD_LINE="${CMD_LINE} asyncmap 00000000"
        fi

        if [ "${PEERDNS}" = "yes" ]
        then
                CMD_LINE="${CMD_LINE} usepeerdns"
        fi

        if [ -n "${IPADDR}${REMIP}" ]
        then
                CMD_LINE="${CMD_LINE} ${IPADDR}:${REMIP}"
        fi

        if [ -n "${NETMASK}" ]
        then
                CMD_LINE="${CMD_LINE} netmask ${NETMASK}"
        fi

        if [ -n "${MRU}" ]
        then
                CMD_LINE="${CMD_LINE} mru ${MRU}"
        fi

        if [ -n "${MTU}" ]
        then
                CMD_LINE="${CMD_LINE} mtu ${MTU}"
        fi

        if [ -n "${USERNAME}" ]
        then
                CMD_LINE="${CMD_LINE} user ${USERNAME} remotename ${PEER}"
        fi

        if [ "${ONDEMAND}" = "yes" ]
        then
                CMD_LINE="${CMD_LINE} demand ktune idle ${IDLETIMEOUT}"
                CMD_LINE="${CMD_LINE} holdoff ${RETRYTIMEOUT}"
        fi
}

setup_cfg_files() {

        if [ "${AUTOCFGFILES}" = "yes" ]
        then
                if [ -n "${NUMBER}" ]
                then
                        # Setup the peers file
                        echo "connect '/usr/sbin/chat -v -f /etc/ppp/chat-${PEER}'" \
                                >/etc/ppp/peers/${PEER}
                fi

                # Setup the secrets files
                echo "\"${USERNAME}\" ${PEER} \"${PASSWORD}\"" >/etc/ppp/chap-secrets
                chmod 600 /etc/ppp/chap-secrets
                echo "\"${USERNAME}\" ${PEER} \"${PASSWORD}\"" >/etc/ppp/pap-secrets
                chmod 600 /etc/ppp/pap-secrets

                # Setup the chat file
                if [ -n "${INITSTRING}" ]
                then
                        sed -e "9i\\'OK\' \'${INITSTRING}\'" \
                                -e "s:\$NUMBER:${NUMBER}:" \
                                ${TEMPLATEDIR}/chat-default \
                                >/etc/ppp/chat-${PEER}
                else
                        sed -e "s:\$NUMBER:${NUMBER}:" \
                                ${TEMPLATEDIR}/chat-default \
                                >/etc/ppp/chat-${PEER}
                fi

                # Setup the ip-scripts so long
                echo '#!/bin/sh' >/etc/ppp/ip-up
                chmod 700 /etc/ppp/ip-up
                echo '#!/bin/sh' >/etc/ppp/ip-down
                chmod 700 /etc/ppp/ip-down

                # Setup if-up and if-down
                if [ -x ${FWSCRIPT} ]
                then
                        echo "${FWSCRIPT} start" >>/etc/ppp/ip-up
                        echo "${FWSCRIPT} stop" >>/etc/ppp/ip-down
                fi

                if [ "${PEERDNS}" = "yes" ]
                then
                        # ip-up: add the server supplied DNS entries to
                        # /etc/resolv.conf
                        echo "/bin/cp -f /etc/resolv.conf /etc/resolv.conf.old" \
                                >>/etc/ppp/ip-up
                        echo "/bin/cat /etc/ppp/resolv.conf >> /etc/resolv.conf" \
                                >>/etc/ppp/ip-up
                        # Change perms because it b0rked kppp
                        echo "chmod 640 /etc/resolv.conf" >>/etc/ppp/ip-up

                        # ip-down: restore original /etc/resolv.conf
                        echo "/bin/mv -f /etc/resolv.conf.old /etc/resolv.conf" \
                                >>/etc/ppp/ip-down
                        echo "chmod 640 /etc/resolv.conf" >>/etc/ppp/ip-down
                fi

                echo "[ -f /etc/ppp/ip-up.local ] && . /etc/ppp/ip-up.local" \
                        >>/etc/ppp/ip-up
                echo "[ -f /etc/ppp/ip-down.local ] && . /etc/ppp/ip-down.local" \
                        >>/etc/ppp/ip-down
        fi
}


# vim:ts=4

110111001001010001010000

Poldi112 ::

moj_nick
Sem skopiral tvoj file, ampak ni delal. Imel je nek error zaradi sintakse. Mogoce zato ker je bil shranjen v win.

big_whale
#/etc/init.d/net.ppp0 start
WARNING: #net.ppp0 has already been started

Zanimivo je da ga ifconfig ne vidi. Postavi pa adsl start avtomaticno gor tudi eth, samo da nima dolocenega ip-ja (prej, ko je se delalo, ga je imel, prav tako ppp0, ki ga sedaj sploh ni pri izpisu od ifconfig).

#tail /var/log/message
pppd: Connect: ppp0 --> /dev/pts/28
pppoe: PADS Service-Name: ' '
pppoe: PPP session is 5209
pppd: LCP terminated by peer --received PADT from peer
pppoe: Sent PADT
pppd: Modem hangup
pppd: Connection terminated
pppd: Exit
adsl-connect: ADSL connection lost; attempting re-connection


------------

Kolk bom jaz zdele lepo spat. Sem nasel da PADT pomeni terminacijo povezave. Potem sem spreminjal razne nastavitve, vklopil se eth pri bootu (prej tega ni bilo treba), mu spreminjal mtu, pobrisal vse ppp config file in jih se enkrat naredil in zdaj dela. Sicer ne vem tocno kaj je bilo narobe, najverjetneje kaka napaka v kakem conf file.
Hvala vsem za pomoc.
btw, huda tale komanda tail.

Zgodovina sprememb…

  • spremenil: Poldi112 ()

Poldi112 ::

No, net in mreza delata, ampak na pol. Adsl po rebootu spet crkne in po adsl-setup zacne delati. Kot da si ne zapomni passworda. In v /etc/conf.d/net imam zapisano, naj mi dvigne eth1. In jo, ampak pri ifconfig izpisu nima ip-ja. Sploh. Ceprav ga ima v net. In ce jo hocem pingat ji ga moram rocno nastaviti.


Vredno ogleda ...

TemaSporočilaOglediZadnje sporočilo
TemaSporočilaOglediZadnje sporočilo
»

Ubuntu in adsl

Oddelek: Operacijski sistemi
202322 (2038) gregs
»

[Linux]add default gateway, slackware

Oddelek: Operacijski sistemi
71017 (915) 'FireSTORM'
»

Gentoo + pppd problem

Oddelek: Operacijski sistemi
7994 (937) R4vn
»

slackware 9.0 in adsl

Oddelek: Operacijski sistemi
91176 (1041) pajac
»

adsl+debian

Oddelek: Omrežja in internet
391530 (1142) Gandalfar

Več podobnih tem