LOMOMAN

lomoman’s life and web

Archive for April, 2009

Windows2003双网卡共享上网的实现

Wednesday, April 29th, 2009

一、固定IP外网接入

    1、wan卡设置ISP提供的固定IP、子网掩码、网关及DNS,并设置为共享;

    2、lan卡设置内网IP(如:192.168.0.1 )、子网掩码(如局域网少于256台机器:255.255.255.0)及DNS;

    3、内网其他机器IP(192.168.0.2 - 192.168.0.255)、子网掩码(255.255.255.0)、网关(192.168.0.1)及DNS(同2);

    4、经过上述设置后基本可以实现Windows2003双网卡共享上网,如主机可以上网而局域网内其他机器不能上则重启ICS服务。

二、ADSL拨号接入

    1、wan卡设为自动获取IP及DNS,接猫;

    2、新建拨号连接,正确输入用户名密码拨号上网,设置为共享;

    3、lan卡设置内网IP(如:192.168.0.1 )、子网掩码(如局域网少于256台机器:255.255.255.0)及DNS;

    4、内网其他机器IP(192.168.0.2 - 192.168.0.255)、子网掩码(255.255.255.0)、网关(192.168.0.1)及DNS(同3);

    5、经过上述设置后基本可以实现Windows2003双网卡共享上网,如主机可以上网而局域网内其他机器不能上则重启ICS服务。

 

P.S. 内网机器的DNS最好设置成本地ISP提供商的DNS号段(如北京网通:202.106.0.20 ;202.106.196.115),尽量避免设置成192.168.0.1(虽然测试成功过)。

Ubuntu Server学习笔记(2)

Monday, April 20th, 2009

基本配置
修改源:sudo vim/etc/apt/sources.list——》按“I”键切换到插入模式
修改镜像地址:http://mirror.lupaworld.com/ubuntu 其它不变,共10条。
保存后 升级:sodo apt-get update
开启SSH服务:sodo apt-get install openssh-server

网络配置
查看网络配置:ifconfig
配置网络:sudo vi /etc/network/interfaces

# The loopback network interface
auto lo
iface lo inet loopback

# The primary network interfaceauto eth0
iface eth0 inet static
address 203.187.182.***
netmask 255.255.255.***
network 203.187.182.***
broadcast 203.187.182.***
gateway 203.187.182.***
# dns-* options are implemented by the resolvconf package, if installed
dns-nameservers 202.106.196.115 202.106.0.20
dns-search workgroup

# The second network interface for intranetauto eth1
iface eth1 inet static
address 192.168.0.123
netmask 255.255.255.0
network 192.168.0.1
broadcast 192.168.0.255
# dns-* options are implemented by the resolvconf package, if installed
dns-nameservers 202.106.196.115 202.106.0.20

新配置生效:sudo /etc.init.d/networking restart
或重启网卡:sodo ifdown eth0
sudo ifup eth0
查看路由信息:route
配置DNS: sudo vi /etc/resolv.conf
nameserver 202.106.196.115
nameserver 202.106.0.20 (可添加3个)

参考:Ray’s Notes - Ubuntu Server 下的网络配置

Ubuntu Server学习笔记(1)

Monday, April 20th, 2009

首先到Ubuntu网站下载64位Server版镜像文件并刻录CD。
服务器配置:
Dell PowerEdge 2800
CPU:Xeon 3.0 ×1 (64bit)
内存:1G (512M×2)
硬盘:SCSI 600G (300G×2)
1.设置光驱启动
开机自检时按F2进入Bios ,进入BOOT SEQUENCE,按“-”使CD_ROM DEVICE到第一位,并按空格键激活“√”,同法令Hard drive C:列位第二,ESC推出、保存。
2.安装系统 (8.10)
进入安装首页,首先选择语言【中文(简体)】——》【Install Ubuntu Server】
键盘选择【NO】,键盘源选择【USA】
设置网络(系统首先会自动DHCP,但大多数情况都会失败)(双网卡选择第1块eth0)选择【Configure network manually】(手动设置网络)——》按顺序设置【IP Address】【Network Mask】【Gateway】【DNS】
设置主机名称【Hostname】——》如联网则自动设置时间
分割及格式化硬盘【MANUAL】(手动)第一块硬盘:根/30G,HOME/266G,SWAP/4G(swap一般为内存2倍,交换空间);第二块硬盘:DATA/300G(ext3)。
安装基本系统……
设置用户名及密码【Full name for the new user】——》【Username for your account】()登录名——》【Choose a new password for the new user】——》【Re-enter password for verify】——》【private directory】是否建立私人目录
安装软件……是否使用代理服务器,否则选择更新方式:【不自动更新 (No automatic updates) 】【自动安装安全更新 (Install security updates automatically)】 【使用 Landscape 管理系统 (Manage system with Landscape)】
选择组合软件:【DNS Server】【LAMP Server】【Mail Server】【OpenSSH Server】【PostgreSQL database】【Print Server】【Samba File Server】【Tomcat Java Server】【Virtual Machine Host】
安装完毕,取出系统盘,重启进入Ubuntu Server。

参考:安装 Ubuntu 服务器 8.10 (Intrepid Ibex)

WEB 前端感言

Wednesday, April 15th, 2009

喜欢PS & CSS,迷上了WEB前端。

作为页面设计师与后台程序员的桥梁,需要把PSD分层转化为HTML+CSS表现出来,并能使后台程序有效的结合进来实现数据交换;

要实现良好的用户体验,必须了解DOM的基本操作,Ajax数据通信的基本原理;

有时也需要自己动手搭建网站运行环境,Windows Server(IIS、FTP、Mailserver)和 Linux(Apache、MySql、PHP)都需要了解。

要具备 结构、表现、行为 分别考虑但又能统一搭配的思想。

现阶段还要使用好多Hack对付不同浏览器带来的烦恼。

自从前些年提出WEB前端这个职业以来,越来越被业界所重视,现如今WEB前端从业者的数量和待遇都在与日俱增,相信其前景会越来越好~

A java applet

Wednesday, April 15th, 2009

This applet is from the book
Core Java
by Cay Horstmann and Gary Cornell,
published by Sun Microsystems Press.

 


The source.

The applet.

Opening

Tuesday, April 14th, 2009

Hello everyone,here my first WP is opening.

Welcome!

You are currently browsing the LOMOMAN blog archives for April, 2009.

LOMOMAN is proudly powered by WordPress YUI theme design by yui
Entries (RSS) and Comments (RSS).