ALT Linux Community general discussions
 help / color / mirror / Atom feed
From: "Мерзляков Евгений Анатольевич" <hj@acoustics.ru>
To: ALT Linux Community general discussions <community@lists.altlinux.org>
Subject: Re: [Comm] Создание шлюза
Date: Mon, 28 Jan 2008 08:43:12 +0500
Message-ID: <200801280843.12982.hj@acoustics.ru> (raw)
In-Reply-To: <479B56F1.3070607@mail.ru>

В сообщении от Saturday 26 January 2008 20:51:13 Alexandr Petukhov написал(а):
> Здравствуйте.
> Ситуация такая:
>
>
> комп с двумя сетевушками
>     eth0   192.168.x.51(городская сеть и VPN)
>     eth2   192.168.0.1
>     шлюз 192.168.x.1
> к eth2 через свитч подключен втророй комп:
>     eth0   192.168.0.2
>     шлюз 192.168.0.1
>
> Соответственно инет  есть тока на первом компьютере.
> Как  настроить таблицу маршрутизации так,чтоб инет  был и на второй машине?

на шлюзе:
iptables -A PREROUTING -t nat -s 192.168.0.1/24 -o eth0 -j SNAT 192.168.x.51
echo 1 >  /proc/sys/net/ipv4/ip_forward

на клиентских машинах установить шлюз по умолчанию 192.168.0.1

-- 
Мерзляков Е.А.
Jabber ID: humptydumpty@jabber.ru

  reply	other threads:[~2008-01-28  3:43 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-01-26 15:51 Alexandr Petukhov
2008-01-28  3:43 ` Мерзляков Евгений Анатольевич [this message]
2008-01-29  8:22   ` Sergey
2008-01-31  8:47   ` Mikhail Kuligin
2008-01-31  9:03     ` Владимир Гусев
2008-01-31  9:10       ` Владимир Гусев
2008-01-31  9:14         ` Владимир Гусев
2008-01-31  9:25           ` Алексей Шенцев
2008-01-31 10:47     ` Мерзляков Евгений Анатольевич
2008-01-31 10:52       ` Мерзляков Евгений Анатольевич
2008-01-31 10:58     ` Motsyo Gennadi aka Drool
2008-01-31 12:06       ` Владимир Гусев
2008-02-01 19:44         ` Mikhail Kuligin
2008-02-01 19:58           ` Slava Dubrovskiy
2008-02-01 20:34           ` Motsyo Gennadi aka Drool
2008-01-31 15:10     ` Vladimir V. Kamarzin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200801280843.12982.hj@acoustics.ru \
    --to=hj@acoustics.ru \
    --cc=community@lists.altlinux.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

ALT Linux Community general discussions

This inbox may be cloned and mirrored by anyone:

	git clone --mirror http://lore.altlinux.org/community/0 community/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 community community/ http://lore.altlinux.org/community \
		mandrake-russian@linuxteam.iplabs.ru community@lists.altlinux.org community@lists.altlinux.ru community@lists.altlinux.com
	public-inbox-index community

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://lore.altlinux.org/org.altlinux.lists.community


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git