1. 一共有二个操作系统,分别为红帽子1、红帽子2。
红帽子2的地址为:eth0 :192.168.1.3
红帽子1的地址为:eth0:192.168.1.2
设定方式:我将红帽子1机器设为NTP server 其他都是为ntp client,也就是说红帽子1和红帽子2的系统时间是同步的。
编辑 /etc/ntp.conf 添加以下内容:
restrict default ignore
restrict 127.0.0.1
restrict 192.168.1.2
restrict 192.168.1.3 mask 255.255.255.0 nomodify
driftfile /etc/ntp/drift
编写完毕以后按Esc,然后保存退出。
接下启动ntp服务
service ntpd start
netstat -unl | grep 123
ntptrace 192.168.1.2
防火墙
iptables -t filter -A INPUT -p udp --sport 123 -j ACCEPT
iptables -t filter -A OUTPUT -p udp --dport 123 -j ACCEPT
时间设置
Date DDDDMMMMYYYY
查看bios时间
Clock -r
保存bios时间
Clock -w
客户端:
service ntpd stop
ntpdate 192.168.1.2
怎么提示
[root@localhost ~]# ntpdate 192.168.1.2
14 Jun 13:58:10 ntpdate[14770]: no server suitable for synchronization found
[root@localhost ~]# ntpdate -d 192.168.1.2
14 Jun 13:40:54 ntpdate[14271]: ntpdate 4.2.2p1@1.1570-o Thu May 14 13:00:58 UTC 2009 (1)
Looking for host 192.168.1.2 and service ntp
host found : 192.168.1.2
transmit(192.168.1.2)
transmit(192.168.1.2)
transmit(192.168.1.2)
transmit(192.168.1.2)
transmit(192.168.1.2)
192.168.1.2: Server dropped: no data
server 192.168.1.2, port 123
stratum 0, precision 0, leap 00, trust 000
refid [192.168.1.2], delay 0.00000, dispersion 64.00000
transmitted 4, in filter 4
reference time: 00000000.00000000 Thu, Feb 7 2036 14:28:16.000
originate timestamp: 00000000.00000000 Thu, Feb 7 2036 14:28:16.000
transmit timestamp: d1a172e9.9f771865 Tue, Jun 14 2011 13:40:57.622
filter delay: 0.00000 0.00000 0.00000 0.00000
0.00000 0.00000 0.00000 0.00000
filter offset: 0.000000 0.000000 0.000000 0.000000
0.000000 0.000000 0.000000 0.000000
delay 0.00000, dispersion 64.00000
offset 0.000000
14 Jun 13:40:58 ntpdate[14271]: no server suitable for synchronization found


age 于 2011-06-15 15:58:43发表:
晕, 目录是目录, 组是组
每个用户都是属于一个组的,对桌面用户来说,一般会建立一个同名的组,如用户aaa,组也是aaa
对于目录test来说,它属于某个用户,也属于某个组。
@ctu,就是指ctu这个组下的所有用户
liuhongming 于 2011-06-15 15:26:07发表:
write list = @ctu 允许ctu组的所有用户访问该共享时可写
什么叫ctu组啊 不是很明白
比如是不是把目录ctu的所有者改成liuhongming: chown liuhongming ctu/
liuhongming是不是就是ctu组的用户啊
age 于 2011-06-15 13:59:37发表:
关iptables效果一样, 相当于开放全部端口
iptables -A INPUT -p tcp -s 192.168.1.0/24 --dport 137-139 -j ACCEPT
iptables -A INPUT -p udp -s 192.168.1.0/24 --dport 137-139 -j ACCEPT
liuhongming 于 2011-06-15 13:56:02发表:
谢谢你 总算成功了 对了 关于第二条怎么开放啊 我是直接把防火墙关了
age 于 2011-06-15 11:32:40发表:
1. samba启动没
2. 137~139 TCP/UDP端口开放没
3. selinux关闭没
liuhongming 于 2011-06-15 11:00:48发表:
我重新编写了一下
在samba服务器端我加了一个liuhongming用户,执行smbpasswd -a liuhongming
在客户端执行
mount //192.168.1.2/share/csi /mnt/ -o username=liuhongming
输入密码以后却出现了一下情况
[root@localhost ~]# mount //192.168.1.2/share/csi /mnt/ -o username=liuhongming
Password:
retrying with upper case share name
mount error 6 = No such device or address
Refer to the mount.cifs(8) manual page (e.g.man mount.cifs)
我是初学者 请大家多多帮忙啊
gogo11 于 2011-06-15 08:48:47发表:
权限不够,操作被拒绝~~~~~~~~~
mount要管理员权限!
liuhongming 于 2011-06-14 15:22:40发表:
1.一共有二个操作系统,分别为红帽子1、红帽子2
红帽子2的地址为:eth0 :192.168.1.3
红帽子1的地址为:eth0:192.168.1.2
(1) 创建4个目录:/share/csi
(2) 将“/share/csi”目录共享,共享名为“csilv”,并满足以下要求
只允许192.168.1.3的客户端访问
所有员工可匿名访问,但是只允许读取文件,不允许修改文件
首先编辑/etc/samba/smb.conf 添加以下内容
[csilv]
comment = shared text
path = /share/csi
public = yes
readonly = yes
hosts deny = ALL
hosts allow = 192.168.1.3
我在红帽子2的客户端上使用如下命令
mount //192.168.1.2/share/csi /mnt/
怎么出现
mount error 13 = Permission denied
Refer to the mount.cifs(8) manual page (e.g.man mount.cifs)