# is openvpn right for me+openvpn problem

## GNUtoo

here the topology of my lan:

.....router(wrt54gs)

.....|...............|

.....|...............|

laptop1......laptop2

.....|

Desktop

laptop1 and Desktop is under gentoo

laptop2 under windows

Desktop get his internet connection from laptop1

i want Desktop to be able to:

*offer services trough the internet such as SSH

by the way i've some little problem between the network of laptop2 and the network of Desktop

*konqueror doesn't find laptop2 in samba shares

*nmap doesn't list mac adress when i type the folowing command:

```
nmap -sP 192.168.1.*
```

Last edited by GNUtoo on Mon Jan 01, 2007 5:26 pm; edited 3 times in total

----------

## lonrot_m

Could you post your smb.conf and ifconfig plz

----------

## GNUtoo

 *lonrot_m wrote:*   

> Could you post your smb.conf and ifconfig plz

 

it's only konqueror that can't find the WINDOWS Desktop...it's not a samba problem

mabe there is some settings somewhere that i can tweek because i think that konqueror search for SMB servers on the network between Desktop and laptop1

----------

## lonrot_m

aahh i see, i had this problem too i solved it putting the info of the computer in the hosts file

----------

## GNUtoo

 *lonrot_m wrote:*   

> aahh i see, i had this problem too i solved it putting the info of the computer in the hosts file

 

so the windows computer must have a static ip and we are under dhcpcd and what also interest me is to see the others windows computer that connect to my wifi  acess point

----------

## GNUtoo

is bridged-openvpn the solution?

----------

## GNUtoo

i tryed bridged openvpn but it didn't work

OpenVPN Server side

```
# cat /etc/openvpn/openvpn.conf

dev tap0

mode server

server-bridge 192.168.1.2 255.255.255.0 192.168.1.120 192.168.1.130

ifconfig-pool-persist /etc/openvpn/sempron/ip_pool

tls-server

dh /usr/share/openvpn/easy-rsa/keys/dh1024.pem

ca /usr/share/openvpn/easy-rsa/keys/ca.crt

cert /usr/share/openvpn/easy-rsa/keys/server.crt

key /usr/share/openvpn/easy-rsa/keys/server.key

```

```
# cat /etc/conf.d/net

# This blank configuration will automatically use DHCP for any net.*

# scripts in /etc/init.d.  To create a more complete configuration,

# please review /etc/conf.d/net.example and save your configuration

# in /etc/conf.d/net (this file :]!).

prefered_aps=("wrt54gs")

blacklist_aps=("SpeedTouch3D86B2" "CAMBRIDGE" "enda" "Sally philips" "Linksys_Avant" "SANTIS50-74F47E" "Hercules")

config_wrt54gs=( "192.168.1.107/24 brd 192.168.0.255" )

routes_wrt54gs=( "default via 192.168.1.1" )

dns_servers_wrt54gs=( "212.68.193.110" "212.68.193.196" )

config_eth0=("192.168.0.2/24 brd 192.168.0.255")

#modules=("openvpn")

tuntap_tap0=("tap")

config_tap0=("192.168.1.121/24")

bridge_br0=("eth0 tap0")

config_br0=("192.168.1.254/24")

brctl_br0=( "stp on" )

depend_br0() {

        need net.eth0 openvpn

}

```

the tap0 device on the server doesn't get an ip automaticaly why?

OpenVPN Client side

```
# cat /etc/openvpn/openvpn.conf

remote 192.168.0.2

dev tap0

#port 5000

client

#ifconfig 192.168.1.122 192.168.1.121

#secret /etc/openvpn/sempron/sempron.key

persist-tun

persist-key

tls-client

ca /etc/openvpn/sempron/ca.crt

cert /etc/openvpn/sempron/semrpron.crt

key /etc/openvpn/sempron/semrpron.key

tls-auth /etc/openvpn/sempron/ta.key

ns-cert-type server

```

```
# cat /etc/conf.d/net

# This blank configuration will automatically use DHCP for any net.*

# scripts in /etc/init.d.  To create a more complete configuration,

# please review /etc/conf.d/net.example and save your configuration

# in /etc/conf.d/net (this file :]!).

dns_domain_lo="workgroup"

#modules=( "iwconfig" )

#config_linksys=("dhcp")

#Prefered acess points

preferred_aps=("wrt54gs")

blacklist_aps=("Hercules" "CAMBRIDGE")

#Acess points settings

config_wrt54gs=( "192.168.1.122/24 brd 192.168.0.255" )

routes_wrt54gs=( "default via 192.168.1.1" )

dns_servers_wrt54gs=( "212.68.193.110" "212.68.193.196" )

#cable settings

#config_eth1=( "192.168.1.122/24 brd 192.168.0.255" )

#routes_eth1=( "default via 192.168.1.1" )

#dns_servers_eth1=( "212.68.193.110" "212.68.193.196" )

#config_eth0=( "192.168.1.122/24 brd 192.168.0.255" )

#routes_eth0=( "default via 192.168.1.1" )

#dns_servers_eth0=( "212.68.193.110" "212.68.193.196" )

#port3 routing settings

config_eth1=("192.168.0.1/24 brd 192.168.0.255")

routes_eth1=("default via 192.168.0.2")

dns_servers_eth1=("212.68.193.110" "212.68.193.196")

#tun device

#tuntap_tun0=("tun")

#config_tun0=("192.168.1.122/24")

#tap device

tuntap_tap0=("tap")

config_tap0=("192.168.1.122/24")

```

OpenVPN Connection:

Jan  1 15:19:15 port3 openvpn[9792]: OpenVPN 2.0.6 i686-pc-linux-gnu [SSL] [LZO] [EPOLL] built on Dec 29 2006

Jan  1 15:19:15 port3 openvpn[9792]: IMPORTANT: OpenVPN's default port number is now 1194, based on an official port number assignment by IANA.  OpenVPN 2.0-beta16 and earlier used 5000 as the default port.

Jan  1 15:19:15 port3 openvpn[9792]: WARNING: --keepalive option is missing from server config

Jan  1 15:19:15 port3 openvpn[9792]: TUN/TAP device tap0 opened

Jan  1 15:19:15 port3 openvpn[9796]: UDPv4 link local (bound): [undef]:1194

Jan  1 15:19:15 port3 openvpn[9796]: UDPv4 link remote: [undef]

Jan  1 15:19:15 port3 openvpn[9796]: Initialization Sequence Completed

----------

## GNUtoo

i kave tryed kovpn but without sucess

----------

## thoughtform

i have openvpn with kovpn working fine in tun mode.

make sure you can connect with /etc/init.d/openvpn start

then you can configure kovpn to manage your connection.

bridge or tap mode is quite noisy as far as broadcasts... is there any reason you're using it instead of tun mode?

----------

## GNUtoo

 *WanderingStar wrote:*   

> i have openvpn with kovpn working fine in tun mode.
> 
> make sure you can connect with /etc/init.d/openvpn start
> 
> then you can configure kovpn to manage your connection.
> ...

 

i need it in order to see samba computers in konqueror

----------

