Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
emerge iptables????
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Spanish
View previous topic :: View next topic  
Author Message
vicens
n00b
n00b


Joined: 20 Feb 2004
Posts: 15

PostPosted: Fri Feb 20, 2004 7:23 pm    Post subject: emerge iptables???? Reply with quote

Hola a todos,

Intento instalarme la iptables, con emerge iptables, pero me da el siguiente error al compilar el paquete:

......
.......
extensions/libipt_ROUTE.c: En la función `init':
extensions/libipt_ROUTE.c:51: error: structure has no member named `flags'
extensions/libipt_ROUTE.c: En la función `parse':
extensions/libipt_ROUTE.c:138: error: structure has no member named `flags'
extensions/libipt_ROUTE.c:138: error: `IPT_ROUTE_CONTINUE' undeclared (first use in this function)
extensions/libipt_ROUTE.c:138: error: (Each undeclared identifier is reported only once
extensions/libipt_ROUTE.c:138: error: for each function it appears in.)
extensions/libipt_ROUTE.c: En la función `print':
extensions/libipt_ROUTE.c:186: error: structure has no member named `flags'
extensions/libipt_ROUTE.c:186: error: `IPT_ROUTE_CONTINUE' undeclared (first use in this function)
extensions/libipt_ROUTE.c: En la función `save':
extensions/libipt_ROUTE.c:209: error: structure has no member named `flags'
extensions/libipt_ROUTE.c:209: error: `IPT_ROUTE_CONTINUE' undeclared (first use in this function)
make: *** [extensions/libipt_ROUTE_sh.o] Error 1

!!! ERROR: net-firewall/iptables-1.2.9 failed.
!!! Function src_compile, Line 53, Exitcode 2
!!! (no error message)


Como me las puedo instalar???

Gracias a todos!!!!!!!
Back to top
View user's profile Send private message
zorth
l33t
l33t


Joined: 17 Feb 2004
Posts: 780
Location: Lovin' Gentoo

PostPosted: Sat Feb 21, 2004 12:26 am    Post subject: Reply with quote

hola. cuando has compilado tu kernel para gentoo durante la instalacion, has dado soporte para iptables en networking? habilitaste la seccion netfilter? si no lo has hecho, dudo que puedas instalar iptables. miratelo.

saludos.
_________________
Geŋtoo Worłd Rułe§
Back to top
View user's profile Send private message
vicens
n00b
n00b


Joined: 20 Feb 2004
Posts: 15

PostPosted: Sat Feb 21, 2004 12:49 pm    Post subject: Reply with quote

Pues cuando instale mi gentoo lo hioce con genkernel, y no se las opciones exactas que me instalo, pero con e modconf he visto que no pud cargar ningun modulo relacionado con las iptables, asi que supongo que ya estaran incluidas en el kernel, pero como lo puedo mirar seguro??

Saludos.
Back to top
View user's profile Send private message
Gentoosiastix
Guru
Guru


Joined: 10 Oct 2003
Posts: 510
Location: Palencia-España

PostPosted: Sat Feb 21, 2004 9:00 pm    Post subject: Reply with quote

si quieres volver a compilarlo y poner las opciones que necesites con genkernel...
# genkernel kernel --menuconfig o a la forma tradicional...
_________________
Siempre seremos novatos en algo
Back to top
View user's profile Send private message
zorth
l33t
l33t


Joined: 17 Feb 2004
Posts: 780
Location: Lovin' Gentoo

PostPosted: Sat Feb 21, 2004 9:20 pm    Post subject: Reply with quote

hola. haz esto a ver si asi consigues tu iptables, que veras como si.

vete a tu /usr/src/linux. ejecuta make menuconfig. lo primero que vas a hacer sera salvar la configuracion de tu kernel actual. para ello, veras abajo LOAD Y SAVE. pica a save y pon por ejemplo, /home/tuusuario/config.kernel.antes.de.cambiar.nada y ahi tendras el archivo que podrias luego CARGAR CON LOAD en caso que no te funcionara el invento, pero seguro que no te hara falta.

entonces, por defecto, te mostrara la configuracion de tu kernel tal y como ahora mismo lo tienes. bien, vete a la seccion de network y pon tus opciones tal como te las pongo a continuacion:

# Networking options
#
CONFIG_PACKET=y
# CONFIG_PACKET_MMAP is not set
# CONFIG_NETLINK_DEV is not set
CONFIG_NETFILTER=y
CONFIG_NETFILTER_DEBUG=y
# CONFIG_FILTER is not set
CONFIG_UNIX=y
CONFIG_INET=y
# CONFIG_IP_MULTICAST is not set
# CONFIG_IP_ADVANCED_ROUTER is not set
# CONFIG_IP_PNP is not set
# CONFIG_NET_IPIP is not set
# CONFIG_NET_IPGRE is not set
# CONFIG_ARPD is not set
# CONFIG_INET_ECN is not set
CONFIG_SYN_COOKIES=y

#
# IP: Netfilter Configuration
#
CONFIG_IP_NF_CONNTRACK=m
CONFIG_IP_NF_FTP=m
# CONFIG_IP_NF_AMANDA is not set
# CONFIG_IP_NF_TFTP is not set
CONFIG_IP_NF_IRC=m
# CONFIG_IP_NF_QUEUE is not set
CONFIG_IP_NF_IPTABLES=y
CONFIG_IP_NF_MATCH_LIMIT=m
CONFIG_IP_NF_MATCH_MAC=m
CONFIG_IP_NF_MATCH_PKTTYPE=m
CONFIG_IP_NF_MATCH_MARK=m
CONFIG_IP_NF_MATCH_MULTIPORT=m
CONFIG_IP_NF_MATCH_TOS=m
CONFIG_IP_NF_MATCH_RECENT=m
CONFIG_IP_NF_MATCH_ECN=m
CONFIG_IP_NF_MATCH_DSCP=m
CONFIG_IP_NF_MATCH_AH_ESP=m
CONFIG_IP_NF_MATCH_LENGTH=m
CONFIG_IP_NF_MATCH_TTL=m
CONFIG_IP_NF_MATCH_TCPMSS=m
CONFIG_IP_NF_MATCH_STEALTH=m
CONFIG_IP_NF_MATCH_HELPER=m
CONFIG_IP_NF_MATCH_STATE=m
CONFIG_IP_NF_MATCH_CONNTRACK=m
CONFIG_IP_NF_MATCH_UNCLEAN=m
CONFIG_IP_NF_MATCH_OWNER=m
CONFIG_IP_NF_FILTER=m
CONFIG_IP_NF_TARGET_REJECT=m
CONFIG_IP_NF_TARGET_MIRROR=m
CONFIG_IP_NF_NAT=m
CONFIG_IP_NF_NAT_NEEDED=y
CONFIG_IP_NF_TARGET_MASQUERADE=m
CONFIG_IP_NF_TARGET_REDIRECT=m
# CONFIG_IP_NF_NAT_LOCAL is not set
CONFIG_IP_NF_NAT_SNMP_BASIC=m
CONFIG_IP_NF_NAT_IRC=m
CONFIG_IP_NF_NAT_FTP=m
CONFIG_IP_NF_MANGLE=m
CONFIG_IP_NF_TARGET_TOS=m
CONFIG_IP_NF_TARGET_ECN=m
CONFIG_IP_NF_TARGET_DSCP=m
CONFIG_IP_NF_TARGET_MARK=m
CONFIG_IP_NF_TARGET_LOG=m
CONFIG_IP_NF_TARGET_ULOG=m
CONFIG_IP_NF_TARGET_TCPMSS=m
CONFIG_IP_NF_ARPTABLES=m
CONFIG_IP_NF_ARPFILTER=m
CONFIG_IP_NF_ARP_MANGLE=m

#
# IP: Virtual Server Configuration
#
# CONFIG_IP_VS is not set
# CONFIG_IPV6 is not set
# CONFIG_KHTTPD is not set
# CONFIG_ATM is not set
# CONFIG_VLAN_8021Q is not set
# CONFIG_IPX is not set
# CONFIG_ATALK is not set

#
# Appletalk devices
#
# CONFIG_DEV_APPLETALK is not set
# CONFIG_DECNET is not set
# CONFIG_BRIDGE is not set
# CONFIG_X25 is not set
# CONFIG_LAPB is not set
# CONFIG_LLC is not set
# CONFIG_NET_DIVERT is not set
# CONFIG_ECONET is not set
# CONFIG_WAN_ROUTER is not set
# CONFIG_NET_FASTROUTE is not set
# CONFIG_NET_HW_FLOWCONTROL is not set

#
# QoS and/or fair queueing
#
# CONFIG_NET_SCHED is not set

#
# Network testing
#
# CONFIG_NET_PKTGEN is not set
CONFIG_IPSEC=m
CONFIG_IPSEC_IPIP=y
CONFIG_IPSEC_AH=y
CONFIG_IPSEC_AUTH_HMAC_MD5=y
CONFIG_IPSEC_AUTH_HMAC_SHA1=y
CONFIG_IPSEC_ESP=y
CONFIG_IPSEC_ENC_3DES=y
CONFIG_IPSEC_ALG=y
# CONFIG_IPSEC_ALG_SHA2 is not set
CONFIG_IPSEC_ALG_AES=m
# CONFIG_IPSEC_ALG_BLOWFISH is not set
CONFIG_IPSEC_ALG_TWOFISH=m
CONFIG_IPSEC_ALG_SERPENT=m
# CONFIG_IPSEC_ALG_CAST is not set
# CONFIG_IPSEC_ALG_NULL is not set
CONFIG_IPSEC_IPCOMP=y
CONFIG_IPSEC_DEBUG=y
CONFIG_IPSEC_NAT_TRAVERSAL=y

ahora, cuando lo hayas puesto tal como te he puesto arriba, vete a EXIT y te preguntara si guarda la nueva configuracion de tu kernel. di YES y haz esto:

1. vete a tu /lib/modules/ y veras el directorio llamado gento..... lo que sea. como root, renombralo a gentoo......-old asi, no machacaremos nada.
2. ahora, en /usr/src/linux haz un make dep
3. make clean
4. make bzImage
5. make modules
6. make modules_install

7. y ya tienes el nuevo kernel compilado. ahora, monta tu particion boot con mount /dev/hdX /boot siendo X donde tengas la particion boot. ahora vete a /boot y renombra tu System.map y tu bzImage con -old para que no se machaque nada.

8. ahora copia tu /usr/src/linux/System.map a /boot
9. copia tu /usr/src/linux/arch/i386/boot/bzImage a /boot
10. reinicia el sistema y rearrancaras con tu nuevo kernel. OJO: la linea de tu grub o lilo, el que uses, debe apuntar al nombre que del nuevo kernel. vigila esto segun como lo tengas tu, ya que yo el bzImage lo renombro siempre como vmlinuz... manias de haber usado debian supongo.
11. si te arranca correctamente como es de suponer, ya tienes iptables. ahora, solo te falta añadir las reglas que desees a iptables.

particularmente, uso un pequeño programita la mar de majo llamado firewall jay. si lo instalas, te podras crear tus propias reglas a gusto del consumidor. cerrando, abriendo puertos, protocolos, redireccion de puertos, NAT, etc. una vez te ha creado tus reglas tan solo te hace falta hacer un /etc/init.d/iptables save para que las guarde por defecto en cada inicio sin necesidad de usar mas el fw-jay para nada hasta que no necesites nuevas reglas a tu medida.

por cierto, para añadir a iptables que se cargue automaticamente en cada inicio, una vez hecho todo lo anterior, tan solo has de poner: rc-update add iptables default

espero que esto te ayude y tranquilo, que si lo haces tal como te he dicho no tendras problemas :)

si puedo ayudar en algo mas solo pidelo. suerte y un saludo.

ps: se me olvidaba!!! lo unico que veras que con el nuevo kernel, no te cargara el driver de la tarjeta grafica en caso de tenerlo acelerado. para ello, vuelve a instalar el nuevo driver que uses y listos. yo uso nvidia y no me queda mas remedio que volver a instalarlo cada vez que toca recompilar kernel... pero bueno, no creo que te sea ese problema.
_________________
Geŋtoo Worłd Rułe§
Back to top
View user's profile Send private message
Mstaaravin
Apprentice
Apprentice


Joined: 09 Apr 2004
Posts: 215
Location: Buenos Aires - Argentina

PostPosted: Fri Apr 09, 2004 5:42 am    Post subject: NO existe en mi maquina ese directorio Reply with quote

Quetal, leyendo tu mensaje y revisando mi maquina me he dado cuenta que en /usr/src/ esta vacio...
no hay ninguna carpeta linux alli.

Saludos
Back to top
View user's profile Send private message
esteban_conde
Veteran
Veteran


Joined: 04 Jun 2003
Posts: 1670

PostPosted: Fri Apr 09, 2004 7:04 am    Post subject: Reply with quote

Vete a la carpeta /usr/portage/sys-kernel
Ahí puedes navegar por la gran variedad de kernels que si has hecho previamente emerge sync el portage te habrá creado, tienes que elegir el que más te guste y decir a emerge que lo baje, ejemplo:
cd /usr/portage/sys-kernel/gentoo-dev-sources
emerge ./gentoo-dev-sources-2.6.4.ebuild
si quieres el último de la saga 2.6
O bien:
cd /usr/portage/sys-kernel/gentoo-sources
emerge ./gentoo-sources-2.4.26_pre6.ebuild
si quieres el último de la saga 2.4
---------------------------------------
Para compilar el 2.4 sigue las instrucciones de zorth (Por cierto zorth ¿Nos conocemos? ...de ya.com)
Para compilar el 2.6 aunque es más fácil al cambiar las opciones un poco deberias leer algo sobre sus caracteristicas, quizás en los docs de gentoo pero en google hay bastante información que de memoria no me atrevo a darte.
Saludos.
Esteban.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Spanish All times are GMT
Page 1 of 1

 
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