iptables로 NAT 구성시 NET: 3 messages suppressed 메시지가..

ktlsu1231의 이미지

안녕하세요.

iptables로 NAT를 구성하였는데
클라이언트에서 인터넷접속을 하면 그에 따라

Quote:

NET: 3 messages suppressed.
NET: 40 messages suppressed.
NET: 138 messages suppressed.
NET: 56 messages suppressed.
NET: 53 messages suppressed.
NET: 8 messages suppressed.
NET: 9 messages suppressed.
NET: 9 messages suppressed.
NET: 9 messages suppressed.
NET: 130 messages suppressed.
NET: 101 messages suppressed.

이런식으로 메시지가 나옵니다.

인터넷속도도 많이 느린데 NAT를 하면서 손실되는 패킷이 많은 것 같습니다.

이 메시지를 제거하려면 어떻게 해야할지 모르겠습니다.

도와주세요. ^^:;

Necromancer의 이미지

웜 조사해보시죠.

제 경험상으로 프락시 돌려서 웹 먹통된다면 100% 웜으로 보시면 됩니다.
프락시까지는 세팅 안하셨겠죠.

Written By the Black Knight of Destruction

ktlsu1231의 이미지

안녕하세요. 상황 설명이 부족했습니다. ^^;;;
케이블모뎀을 NAT역할을 하는 리눅스에 연결을 하고,
Iptables을 사용하여 아래와 같이 설정하였습니다.

Quote:

ifconfig eth0:1 192.168.10.1 netmask 255.255.255.0 up
echo "1" > /proc/sys/net/ipv4/ip_dynaddr
echo "1" > /proc/sys/net/ipv4/ip_forward

/usr/nat/iptables -t nat -A POSTROUTING -o eth0 -s 192.168.10.0/24 -j MASQUERADE

/usr/nat/iptables -A FORWARD -p tcp --tcp-flags SYN,RST SYN -j TCPMSS --clamp-mss-to-pmtu


위 설정내용은 RH7.3에서 테스트 해보았고 이상없이 작동하였습니다.

그런데 Kernel2.4.5를 구해 다른 기기에 설치해 적용하니 문제가 생기네요. --?
클라이언트에서 IP 설정을 하고 라눅스를 Gateway로 하여
외부로 나가면 리눅스에서

Quote:

NET: 3 messages suppressed.
NET: 40 messages suppressed.
NET: 138 messages suppressed.
NET: 56 messages suppressed.
NET: 53 messages suppressed.
NET: 8 messages suppressed.
NET: 9 messages suppressed.
NET: 9 messages suppressed.
NET: 9 messages suppressed.
NET: 130 messages suppressed.
NET: 101 messages suppressed.

이런메시지가 주루루룩 나옵니다. 클라이언트에서 인터넷으로 ping을
보내거나 웹페이지 접속을 하면 그 전송량에 따라
NET: 요부분 messages suppressed.
요부분의 숫자가 커지고 작아집니다.

iptables1.2.6과 1.2.5을 컴파일 할 때는

make NO_SHARED_LIBS=1

위와 같이 하였구요. 1.2.5에 이상이 있나 싶어 1.2.6으로 해보았는데
동일하였습니다.
도와주세요..

ktlsu1231의 이미지

Quote:

Re: "(...) messages supressed" ?
Forum: SecurePoint - Netfilter mailing list archive
Date: 2001, Nov 05
From: Guillaume Morin <nobody at nowhere.com>

Dans un message du 05 nov ? 0:26, Pedro Fonseca ?rivait :
> Can anyone tell me what's this that appears every now and then in my logs?
>
> Nov 5 00:18:59 myhost kernel: NET: 1 messages suppressed.

Your log daemon has suppressed a duplicate line. It is normal.

--
Guillaume Morin <guillaume AT morinfr DOT org>

Marry me girl, be my only fairy to the world (RHCP)

That's actually a kernel message generated out of ./net/core/utils.c.
At one time, that code was buggy and suppressed the original message as
well as the duplicates; haven't looked at it in a while though...

-Tom

이게 무슨 소린가요?

NET: %d messages suppressed. 가 나오는 것은 정상이라는 말인가요?

Quote:

1 /*
2 * Generic address resultion entity
3 *
4 * Authors:
5 * net_random Alan Cox
6 * net_ratelimit Andy Kleen
7 *
8 * Created by Alexey Kuznetsov <kuznet@ms2.inr.ac.ru>
9 *
10 * This program is free software; you can redistribute it and/or
11 * modify it under the terms of the GNU General Public License
12 * as published by the Free Software Foundation; either version
13 * 2 of the License, or (at your option) any later version.
14 */
15
16 #include <asm/uaccess.h>
17 #include <asm/system.h>
18 #include <linux/types.h>
19 #include <linux/kernel.h>
20 #include <linux/sched.h>
21 #include <linux/string.h>
22 #include <linux/mm.h>
23
24 static unsigned long net_rand_seed = 152L;
25
26 unsigned long net_random(void)
27 {
28 net_rand_seed=net_rand_seed*69069L+1;
29 return net_rand_seed^jiffies;
30 }
31
32 void net_srandom(unsigned long entropy)
33 {
34 net_rand_seed ^= entropy;
35 net_random();
36 }
37
38 int net_msg_cost = 5*HZ;
39 int net_msg_burst = 10*5*HZ;
40
41 /*
42 * This enforces a rate limit: not more than one kernel message
43 * every 5secs to make a denial-of-service attack impossible.
44 *
45 * All warning printk()s should be guarded by this function.
46 */
47 int net_ratelimit(void)
48 {
49 static spinlock_t ratelimit_lock = SPIN_LOCK_UNLOCKED;
50 static unsigned long toks = 10*5*HZ;
51 static unsigned long last_msg;
52 static int missed;
53 unsigned long flags;
54 unsigned long now = jiffies;
55
56 spin_lock_irqsave(&ratelimit_lock, flags);
57 toks += now - last_msg;
58 last_msg = now;
59 if (toks > net_msg_burst)
60 toks = net_msg_burst;
61 if (toks >= net_msg_cost) {
62 int lost = missed;
63 missed = 0;
64 toks -= net_msg_cost;
65 spin_unlock_irqrestore(&ratelimit_lock, flags);
66 if (lost)
67 printk(KERN_WARNING "NET: %d messages suppressed.\n", lost);
68 return 1;
69 }
70 missed++;
71 spin_unlock_irqrestore(&ratelimit_lock, flags);
72 return 0;
73 }

커널 소스 인데요. 주석에 make a denial-of-service attack impossible 이렇게 나와있네요. DoS 공격을 막기 위한 것일까요? RHLinux 7.3에선 동일한
설정과 네트웍 환경에서도 이런 메시지 안나왔는데. T_T 에혀..

댓글 달기

Filtered HTML

  • 텍스트에 BBCode 태그를 사용할 수 있습니다. URL은 자동으로 링크 됩니다.
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param><hr>
  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.

BBCode

  • 텍스트에 BBCode 태그를 사용할 수 있습니다. URL은 자동으로 링크 됩니다.
  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param>
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.

Textile

  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • You can use Textile markup to format text.
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param><hr>

Markdown

  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • Quick Tips:
    • Two or more spaces at a line's end = Line break
    • Double returns = Paragraph
    • *Single asterisks* or _single underscores_ = Emphasis
    • **Double** or __double__ = Strong
    • This is [a link](http://the.link.example.com "The optional title text")
    For complete details on the Markdown syntax, see the Markdown documentation and Markdown Extra documentation for tables, footnotes, and more.
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param><hr>

Plain text

  • HTML 태그를 사용할 수 없습니다.
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.
  • 줄과 단락은 자동으로 분리됩니다.
댓글 첨부 파일
이 댓글에 이미지나 파일을 업로드 합니다.
파일 크기는 8 MB보다 작아야 합니다.
허용할 파일 형식: txt pdf doc xls gif jpg jpeg mp3 png rar zip.
CAPTCHA
이것은 자동으로 스팸을 올리는 것을 막기 위해서 제공됩니다.