分享
 
 
 

新手必读(solaris基础和常用知识三)

王朝other·作者佚名  2008-05-19
窄屏简体版  字體: |||超大  

新手必读(solaris基础和常用知识)

作者:boycw 转载时间:2002-12-25

101 Q: 我们有一个产品在移植到SOLARIS的过程中出现了大量难以理解的问题,请给

我们现场支援一下,非常感谢!使用Forte Develop6编译C++程序的时候出现

以下信息:

"mit/../teglobal.h", line 39: Warning (Anachronism): Attempt to redefine TRUE without using #undef.

"mit/../teglobal.h", line 40: Warning (Anachronism): Attempt to redefine FALSE without using #undef.

Assertion: (../links/prepexpression.cc, line 65)

while processing mit/multilock.cpp at line 0.

请问是什么意思,难道编译器还要assert吗?

A: CC 编译器要求被编译的文件以两个新行结束,请在相关头文件末尾加上新行。

102 Q: solaris的问题:激活小键盘上的Numlock,激活中文输入法,按小键盘上的0

键,中文输入法自行关闭,请问是何原因?

A: You can solve the problem you metioned by trying the following three

ways:

1. Make sure using GB locale, instead of GBK.

2. Visit http://sunsolve.sun.com to get the "recommended patches"

package for the your solaris platform, and add it.

3. If possible, you can change the solaris platform from solaris 2.7

to solaris 2.8

103 Q: 有关在SOLARIS上使用NETSCAPE问题

问题描述:

1.在SOLARIS2.6上安装NETSCAP4.04后,安装提示成功后,运行netscape,出现以

下错误信息:

xlib:connection to "0.0" refused by server

xlib:client is not authorized to server

can't open display : :0.0

2.在SOLARIS2.6上安装Acroread后,如何设置能直接点击打开.pdf文件,而无需

每次要先启动Acroread,然后再打开? 请问上述问题如何解决?

A: 1. You run the command:

#xhost :0.0

and then, you can use NETSCAPE In the terminal, in which the

netscape is launched, please set the envrionment DISPLAY as :0.0

2. Actually, I don't know how to configure it. If you are interested

in it. You can read some topics in AnswerBook2 User Collection.

104 Q: syslogd 如何支持汉字? syslogd 好像会把汉字拆分成两个字节,并去掉高位

如何解决?

A: How the background service provider syslogd supports character set

depends on the locale environment it starts. So, if you want Chinese

characters transferring by syslog. You can restart syslogd in

Chinese environment by issuing the following commands:

# LANG=zh; export LANG # set the locale environment in Chinese.

# kill -9 `cat /etc/syslog.pid` # to kill the former syslogd

# /usr/sbin/syslogd

If you want syslogd to support Chinese characters whenever the

machine boot. Put the attacted file in the /etc/rc3.d directory.Make

sure this file's mode is "rwxr-xr-x" and the owner is root.

105 Q: 我的工作站的交换分区分的太小了,除重装系统外,是否有其它办法将空间调

整一下。

A: You can extend your swap region by issueing the following command:

#mkfile -m

#swap -a

Note: the should be the full path name.

106 Q: 用vi打开一个script文件,发现里面有非法字符^M,在vi命令行如何全程替代

掉该字符?我试了一下用以下命令来做,却不行:0,$s/^M//

A: 1,$s/^M//g ,其中,^M是 ctrl+V ,ctrl+M,或者,用下面这个命令。

%unix2dos $filename $newfilename

107 Q: How to add space to a filesystem in solaris2.5.7 ? When I patchadd a

patch,It tell me that there is no sufficient filesystem capacity.

A: It seems like your root partition too small. Please check it

availiable size. If it is small, I think you would better to

reinstall the system. Please store all the data in the disk.

In the new installation, you need really to partitions, one is for

swap, and another is for /. The swap partition /tmp needs about 200M

to 500M. Then all the left should be given to /.

108 Q: 请教关于Solaris Patch的问题。我们在安装一些软件时,经常需要先安装一

些Patch,有一事不明,向您请教一下,比如某个软件需要Patch : 107546-02,

现在我的机器上已经安装107546-08,是不是就不用再安装107546-02了Patch

后面的那部分是什么意思?是不是大的数字可以包含小的数字的功能了? 同一

个Patch的不同版本之间会不会有冲突?

A: You are right. If you have installed a bigger version of the same

patch, it not necessary for you to install the smaller one. The

bigger version will override the earlier one if it installed before.

You need not worry about any collision.

109 Q: 关于sun的SunNet 我目前想了解关于sun的SunNet。我从sun的网站上了解到

SunNet已经被合并入到Solstice里了,我目前想试着把我做得程序集成到

SunNet或Solstice里,我看了Slostice得White Paper,但里边只提到了一点点

相关得Api,我从哪里,怎么才能到比较完全得文档呢?

A: To my knowledge, you can go to the following for a detailed info:

http://www.sun.com/software/solstice/em-products/network/sunnetmgr.html.

110 Q: 关于SUN机器root口令丢失问题,如何解决?

A: 办法如下:

利用SOLARIS的启动盘来启动,然后把硬盘mount上去,修改硬盘上原etc目录

下的shadow文件,将root项里的password域内容删除,变成无密码。然后重新

启动主机,以无密码的root登陆后,重新设置root口令。具体步骤如下:

1.把你的solaris光盘放进cdrom

2.键入stop+a

3.当出现'ok'字样时,键入boot cdrom -s

4.cd /tmp/root

5.mkdir /tmp/root/xxx (xxx是什么鬼东西就无关紧要了)

6.mount /dev/dsk/c0t0d0s0 /tmp/root/xxx (在这里c0t0d0s0是你的root盘)

7.运行csh

8.setenv TERM vt220

9.cp /tmp/root/xxx/etc/shadow /tmp/root/xxx/shadow/shadow.bak

10.vi /tmp/root/xxx/shadow,并且将root项里的password域删除即可。

11.重启动,你就可以以无密码的root登陆了,登录后,更改root的密码。

111 Q: In solaris 2.6. when i use command "killall" ,all process started in

CDE will be killed and the eviroment will change to CDE login. I

looked up the man manual about "killall" ,it told me that "only root

can use the command".But I really use it with common id.In

solaris7 and solairs 8, with common id,i can't use the common.can

you tell me why i can execute "killall" successfully in solaris 2.6?

A: Just see the access mode of /usr/sbin/killall. If you can use it

with a common account identity, the access mode should be x-rsx-rx-r.

If you can not use it in a common account identity, the mode should

be x-r--r--r. You can change the mode as you like, whenever in 2.6,

or 2.7 or 2.8.

112 Q: I downloaded the SDM2.3 from the Download Center of "www.sun.com"

,read the White Paper and web detailed describing.But it is only the

outlook of the software. I need the detailed document about how to

integrated my own network management application to Solstice.

A: I transfer this messag to Sun Service in Guangdong.

113 Q: 请问有没有磁盘管理工具。我们有一台E450,有5块硬盘,想做RAID,但是没有工

具.

A: If the machine's OS is solaris 2.8, the storage management software

is also installed in you machine. You can make the RAID by issuing

the command family: /usr/sbin/meta*; If you are not so familiar with

these commands. I can do it for you. or you can use solstice

disksuite, it is a GUI tool.

114 Q: 怎样强制更改NIS客户端的本地NIS数据表?有时候NIS客户端和NIS服务器端有

时会出现不一致的情况.NIS服务器和NIS slave 服务器也会出现这种情况。

A: 你可以用yppush和 ypxfr 来做这种工作,更常见的方法是把它们写进cron,定

期更新,具体步骤请查阅Answerbook.

115 Q: 为了将工作站设为从DHCP动态分配IP,并且将主机名由"unknown"改为原名

修改了/etc/init.d/rootusr,将dhcpinfo后面三行(不是四行)注释掉;

hostname=`/sb

 
 
 
免责声明:本文为网络用户发布,其观点仅代表作者个人观点,与本站无关,本站仅提供信息存储服务。文中陈述内容未经本站证实,其真实性、完整性、及时性本站不作任何保证或承诺,请读者仅作参考,并请自行核实相关内容。
2023年上半年GDP全球前十五强
 百态   2023-10-24
美众议院议长启动对拜登的弹劾调查
 百态   2023-09-13
上海、济南、武汉等多地出现不明坠落物
 探索   2023-09-06
印度或要将国名改为“巴拉特”
 百态   2023-09-06
男子为女友送行,买票不登机被捕
 百态   2023-08-20
手机地震预警功能怎么开?
 干货   2023-08-06
女子4年卖2套房花700多万做美容:不但没变美脸,面部还出现变形
 百态   2023-08-04
住户一楼被水淹 还冲来8头猪
 百态   2023-07-31
女子体内爬出大量瓜子状活虫
 百态   2023-07-25
地球连续35年收到神秘规律性信号,网友:不要回答!
 探索   2023-07-21
全球镓价格本周大涨27%
 探索   2023-07-09
钱都流向了那些不缺钱的人,苦都留给了能吃苦的人
 探索   2023-07-02
倩女手游刀客魅者强控制(强混乱强眩晕强睡眠)和对应控制抗性的关系
 百态   2020-08-20
美国5月9日最新疫情:美国确诊人数突破131万
 百态   2020-05-09
荷兰政府宣布将集体辞职
 干货   2020-04-30
倩女幽魂手游师徒任务情义春秋猜成语答案逍遥观:鹏程万里
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案神机营:射石饮羽
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案昆仑山:拔刀相助
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案天工阁:鬼斧神工
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案丝路古道:单枪匹马
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案镇郊荒野:与虎谋皮
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案镇郊荒野:李代桃僵
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案镇郊荒野:指鹿为马
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案金陵:小鸟依人
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案金陵:千金买邻
 干货   2019-11-12
 
推荐阅读
 
 
 
>>返回首頁<<
 
靜靜地坐在廢墟上,四周的荒凉一望無際,忽然覺得,淒涼也很美
© 2005- 王朝網路 版權所有