Pessoal; Peguei o seguinte receita de bolo para fazer uma rede usando usb de meu notebook com meu iPaq: ----------------------inicio----------------------- PC side ------- 1 - Append /etc/hosts with the IPs (and names) of your iPAQ and your PC: # echo "192.168.0.200 mypc" >> /etc/hosts # echo "192.168.0.202 ipaq" >> /etc/hosts 2 - Put this line in the end of /etc/rc.d/rc.local: # echo "/etc/rc.d/rc.ipaq" >> /etc/rc.d/rc.local 3 - Create the file /etc/rc.d/rc.ipaq and change its permissions to 755: #!/bin/bash # Masquerading/Forwarding # Be careful! These rules are not safe! /sbin/modprobe ip_tables /sbin/modprobe iptable_filter /sbin/modprobe ip_conntrack /sbin/modprobe ip_conntrack_ftp /sbin/modprobe ip_conntrack_irc /sbin/modprobe iptable_nat /sbin/modprobe ip_nat_ftp /sbin/modprobe ip_nat_ftp /sbin/modprobe ip_nat_irc echo "1" > /proc/sys/net/ipv4/ip_forward /sbin/iptables -P INPUT ACCEPT /sbin/iptables -F INPUT /sbin/iptables -P OUTPUT ACCEPT /sbin/iptables -F OUTPUT /sbin/iptables -P FORWARD ACCEPT /sbin/iptables -F FORWARD /sbin/iptables -F -t nat /sbin/iptables -Z # Change eth0 to whatever is your interface for the Internet! /sbin/iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE # USB Networking /sbin/modprobe usbnet 4 - Create the file /etc/sysconfig/network-scripts/ifcfg-usb0: DEVICE=usb0 IPADDR=192.168.0.200 NETMASK=255.255.255.0 NETWORK=192.168.0.0 BROADCAST=192.168.0.255 ONBOOT=no 5 - Run /etc/rc.d/rc.ipaq: # /etc/rc.d/rc.ipaq DONE! -----------------------fim------------------------ Como esta receita foi feita para RedHat, nao consegui visualizar como eu implementaria as diferencas no debian. EG: nao existe o diretorio /etc/sysconfig/network-scripts/, mas sim o /etc/network. Fiquei perdio, mesmo com a ajuda do manual guia pratico do debian. Alguem poderia "adaptar" esta receita para eu implementar? Em tempo: A rede usb ja esta funcionando, consegui estabelecer usando os comandos no shell, mas gostaria de automatizar a coisa. []'s -- Marcio de Araujo Benedito <china@pbh.gov.br> Prodabel S/A
Attachment:
signature.asc
Description: PGP signature