No chain/target/match by that name
estou tentando usar essa regra:
iptables -t mangle -A OUTPUT -p tcp -j TOS --dport 80 --set-tos 0x10
mais sempre tenho o erro:
No chain/target/match by that name
já carreguei esses modulos mais nada:
modprobe ip_queue
modprobe ip_tables
modprobe ipt_ECN
modprobe ipt_LOG
modprobe ipt_MASQUERADE
modprobe ipt_NETMAP
modprobe ipt_REDIRECT
modprobe ipt_REJECT
modprobe ipt_TTL
modprobe ipt_addrtype
modprobe ipt_ah
modprobe ipt_iprange
modprobe ipt_owner
modprobe ipt_recent
modprobe ipt_tos
modprobe iptable_filter
modprobe iptable_mangle
modprobe iptable_nat
modprobe iptable_raw
modprobe nf_conntrack_ipv4
modprobe nf_nat
modprobe nf_nat_amanda
modprobe nf_nat_ftp
modprobe nf_nat_h323
modprobe nf_nat_irc
modprobe nf_nat_pptp
modprobe nf_nat_proto_gre
modprobe nf_nat_sip
modprobe nf_nat_snmp_basic
modprobe nf_nat_tftp
modprobe ipt_REJECT
modprobe ipt_LOG
modprobe iptable_mangle
modprobe iptable_filter
modprobe iptable_nat
modprobe ip_nat_ftp
modprobe ip_conntrack
modprobe ip_conntrack_ftp
modprobe ip_conntrack_irc
modprobe ip_nat_irc
modprobe ipt_mac
modprobe ipt_state
modprobe ipt_mark
modprobe ip_nat_pptp
modprobe ip_conntrack_pptp
é preciso algo especifico para essa regra funcionar ?
iptables -t mangle -A OUTPUT -p tcp -j TOS --dport 80 --set-tos 0x10
obrigado por me ajudar, abaixo o iptables -t mangle -nL
Chain PREROUTING (policy ACCEPT)
target prot opt source destination
Chain INPUT (policy ACCEPT)
target prot opt source destination
Chain FORWARD (policy ACCEPT)
target prot opt source destination
Chain OUTPUT (policy ACCEPT)
target prot opt source destination
Chain POSTROUTING (policy ACCEPT)
target prot opt source destination
não conseguir carregar o modulo x_tab less aqui tb, vc pode informar se é necessário compilar o kernel com o netfilter para funcionar, estou meio sem tempo e não queria arriscar a compilar sem ter certeza se será a solução.....
iptables -t mangle -A OUTPUT -p tcp -j TOS --dport 80 --set-tos 0x10
nada continua o erro, esquecir de fala ipt_TOS não funciona aqui somente ipt_tos com tos minusculo minha distro é o debian lenny e o iptables é o 1.4.2 ....
iptables -t mangle -A OUTPUT -p tcp -j TOS --dport 80 --set-tos 0x10
Pirigoso eu tb já havia tentando dessa forma pois tb desconfiei da sintaxe mais ficou na mesma Sergio tentei sudo iptables -t mangle -A OUTPUT -p tcp -j MARK --dport 80 --set-mark 3 mais ocorre o mesmo erro, tb testei em um Ubuntu aqui e funcionou beleza, reinstalei o iptables para 1.4.4 e tb não resolveu acho como vc Sergio que é algum módulo que falta carregar. Se for do interesse testar a distro do erro para tirar as dúvidas, a ISO se encontra aqui http://hotfile.com/dl/7073478/fc40e2...thv37.iso.html é um arquivo de 190MB e o como instalação a mesma nesse link http://www.pedrofilho.com.br/manual/pag02.php ela é livecd pode-se testa sem instalar, ela é um remaster do debian lenny. Obrigado pela ajuda de vcs....
iptables -t mangle -A OUTPUT -p tcp -j TOS --dport 80 --set-tos 0x10
Citação:
Postado originalmente por
sergio
Pedro, pelo visto este Kernel, como foi remasterizado está faltando algo no iptables. Se rodar um make menuconfig, e acessar o netfilter, quais os módulos que lá estão? Parece que o mangle não está carregando apropridadamente. Roda o comando que o Piri passou e vejamos a saida do mesmo.
iptables -m tos --help
formatei novamente aqui para não ter erro de algo que fiz tem alterado alguma coisa.
make menuconfig:
make: *** Sem regra para processar o alvo `menuconfig'. Pare.
iptables -m tos --help:
iptables v1.4.2
Usage: iptables -[AD] chain rule-specification [options]
iptables -[RI] chain rulenum rule-specification [options]
iptables -D chain rulenum [options]
iptables -[LS] [chain [rulenum]] [options]
iptables -[FZ] [chain] [options]
iptables -[NX] chain
iptables -E old-chain-name new-chain-name
iptables -P chain target [options]
iptables -h (print this help information)
Commands:
Either long or short options are allowed.
--append -A chain Append to chain
--delete -D chain Delete matching rule from chain
--delete -D chain rulenum
Delete rule rulenum (1 = first) from chain
--insert -I chain [rulenum]
Insert in chain as rulenum (default 1=first)
--replace -R chain rulenum
Replace rule rulenum (1 = first) in chain
--list -L [chain [rulenum]]
List the rules in a chain or all chains
--list-rules -S [chain [rulenum]]
Print the rules in a chain or all chains
--flush -F [chain] Delete all rules in chain or all chains
--zero -Z [chain] Zero counters in chain or all chains
--new -N chain Create a new user-defined chain
--delete-chain
-X [chain] Delete a user-defined chain
--policy -P chain target
Change policy on chain to target
--rename-chain
-E old-chain new-chain
Change chain name, (moving any references)
Options:
[!] --proto -p proto protocol: by number or name, eg. `tcp'
[!] --source -s address[/mask]
source specification
[!] --destination -d address[/mask]
destination specification
[!] --in-interface -i input name[+]
network interface name ([+] for wildcard)
--jump -j target
target for rule (may load target extension)
--goto -g chain
jump to chain with no return
--match -m match
extended match (may load extension)
--numeric -n numeric output of addresses and ports
[!] --out-interface -o output name[+]
network interface name ([+] for wildcard)
--table -t table table to manipulate (default: `filter')
--verbose -v verbose mode
--line-numbers print line numbers when listing
--exact -x expand numbers (display exact values)
[!] --fragment -f match second or further fragments only
--modprobe=<command> try to insert modules using this command
--set-counters PKTS BYTES set the counter during insert/append
[!] --version -V print package version.
tos match options:
[!] --tos value[/mask] Match Type of Service/Priority field value
[!] --tos symbol Match TOS field (IPv4 only) by symbol
Accepted symbolic names for value are:
(0x10) 16 Minimize-Delay
(0x08) 8 Maximize-Throughput
(0x04) 4 Maximize-Reliability
(0x02) 2 Minimize-Cost
(0x00) 0 Normal-Service
estou começando a achar que o kernel tb.....
iptables -t mangle -A OUTPUT -j TOS --set-tos 0x10
Citação:
Postado originalmente por
sergio
hummm... para rodar o make menuconfig voce deve ter os fontes do kernel instalado.
Aparentemente o módulo tos está instalado e funcionando. Vamos testar apenas o TOS.
iptables -t mangle -A OUTPUT -j TOS --set-tos 0x10
Mesmo erro Sergio, acho que é o kernel mesmo irei instalar outro para fazer um teste, obrigado...