REDHAT linux XDMCP配置

[不指定 2007/07/10 15:05 | by ipaddr ]

配置XDMCP,可以在WINDOWS下通过XMANAGER等工具访问linux桌面,配置方法如下:

1.修改/etc/X11/xdm/Xaccess文件如下:
* # any host can get a login window
(
说明:即把这句语句的前面一个#符去掉)
2.
修改/etc/X11/gdm/gdm.conf文件
[xdmcp]
Enable=false
 改为Enable=1Enable=true
3
.修改 /etc/inittab文件
id:3:initdefault
改为id:5:initdefault (有些linux版本已是id:5:initdefault就不需要改)
最后一行改为: x:5:respawn:/usr/bin/gdm
4.
修改/etc/X11/xdm/xdm-config文件
displayManager.requestPort : 0 前面加上!符号,用于注释这行
(说明:这语句在这文件的最后一行)
5
/etc/X11/xdm/Xservers中将:0 local /usr/X11R6/bin/X 注释掉 #:0 local /usr/X11R6/bin/X
(可以处理此步骤)
6.
修改防火墙,防火墙关闭的就不用修改:
  /etc/sysconfig/ipchains文件中加入以下语句:
-A input -p udp -s 0/0 -d 0/0 177 -j accept
7
、在/etc/hosts中加入相应主机的解析(如不加可能登陆不进界面)
6.
重启机器
7.
windows下使用xmanager登录
SubInACL is a command-line tool that enables administrators to obtain security information about files, registry keys, and services, and transfer this information from user to user, from local or global group to group, and from domain to domain. For example, if a user has moved from one domain (DomainA) to another (DomainB), the administrator can replace DomainA\User with DomainB\User in the security information for the user's files. This gives the user access to the same files from the new domain.

SubInACL enables administrators to do the following:
  • Display security information associated with files, registry keys, or services. This information includes owner, group, permission access control list (ACL), discretionary ACL (DACL), and system ACL (SACL).
  • Change the owner of an object.
  • Replace the security information for one identifier (account, group, well-known security identifier (SID)) with that of another identifier.
  • Migrate security information about objects. This is useful if you have reorganized a network's domains and need to migrate the security information for files from one domain to another.

Windows2003批量修改文件属主,可参考如下命令:
[code]SubInAcl /subdirectories C:\Home /replace=olduser=newuser[/code]

XML指南-转义字符

[不指定 2007/06/25 17:27 | by ipaddr ]

解析数据
XML 解析器通常情况下会处理XML文档中的所有文本。

当XML元素被解析的时候,XML元素内部的文本也会被解析:

<message>This text is also parsed</message>


XML解析器这样做的原因是XML元素内部可能还包含了别的元素,象下面的例子,name元素内部包含了first和last两个元素:

<name><first>Bill</first><last>Gates</last></name>
 

解析器会认为上面的代码是这样的:

<name>
<first>Bill</first>
<last>Gates</last>
</name>

--------------------------------------------------------------------------------

转义字符
不合法的XML字符必须被替换为相应的实体。

如果在XML文档中使用类似"<" 的字符, 那么解析器将会出现错误,因为解析器会认为这是一个新元素的开始。所以不应该象下面那样书写代码:

<message>if salary < 1000 then</message>

为了避免出现这种情况,必须将字符"<" 转换成实体,象下面这样:

<message>if salary &lt; 1000 then</message>


下面是五个在XML文档中预定义好的实体:

&lt; < 小于号
&gt; > 大于号
&amp; & 和
&apos; ' 单引号
&quot; " 双引号

实体必须以符号"&"开头,以符号";"结尾。

注意: 只有"<" 字符和"&"字符对于XML来说是严格禁止使用的。剩下的都是合法的,为了减少出错,使用实体是一个好习惯。


--------------------------------------------------------------------------------

CDATA部件
在CDATA内部的所有内容都会被解析器忽略。

如果文本包含了很多的"<"字符和"&"字符——就象程序代码一样,那么最好把他们都放到CDATA部件中。

一个 CDATA 部件以"<![CDATA[" 标记开始,以"]]>"标记结束:

<script>
<![CDATA[
function matchwo(a,b)
{
if (a < b && a < 0)
then
 { return 1 }
else { return 0 } }
]]>
</script>

 


在前面的例子中,所有在CDATA部件之间的文本都会被解析器忽略。

CDATA注意事项:
CDATA部件之间不能再包含CDATA部件(不能嵌套)。如果CDATA部件包含了字符"]]>" 或者"<![CDATA[" ,将很有可能出错哦。

同样要注意在字符串"]]>"之间没有空格或者换行符。

在Windows 2000环境中安装PEAR

[不指定 2007/06/24 23:36 | by ipaddr ]
一、什么是PEAR

  PEAR是PHP Extension and Application Repository(PHP扩展与应用库)的缩写。PEAR为PHP用户提供了一套基本类库,在编写PHP程序时通过调用相关的PEAR类可以简化我们的工作量。举个很简单的例子,比如我在程序中想把数据库中的数据通过Web页面的条件设定,抽取相应的数据转存到Excel表格里。要完成这个任务,在以前可不是很容易办到的,还好现在有了PEAR,通过调用PEAR里面的Spreadsheet类,我们可以在很短的时间实现对Excel的写操作。长话短说,还是开始尽快我们的PEAR安装之旅吧。
64位Linux系统下,源码编译时,有时会无法链接libmysqlclient库:

/usr/bin/ld: skipping incompatible /usr/lib/mysql/libmysqlclient.so when searching for -lmysqlclient
/usr/bin/ld: skipping incompatible /usr/lib/mysql/libmysqlclient.a when searching for -lmysqlclient

请将Makefile里面的
-L/usr/lib/mysql
改为
-L/usr/lib64/mysql

---------------
或者:
----------------
# cd /usr/lib
# mv lib lib.bak
# ln -s /usr/lib64/mysql /usr/lib/mysql
# tar -jxvf httpd-2.2.3.tar.bz2
# cd httpd-2.2.3
# ./configure LDFLAGS="-L/usr/lib64 -L/lib64" --enable-so --enable-rewrite --enable-cgi
# vi ./srclib/apr-util/Makefile


APRUTIL_LIBS = -lsqlite3 /usr/lib/libexpat.la /root/tar/httpd-2.2.3/srclib/apr/libapr-1.la -luuid -lrt -lcrypt -lpthread -ldl
改为
APRUTIL_LIBS = -lsqlite3 /usr/lib64/libexpat.la /root/tar/httpd-2.2.3/srclib/apr/libapr-1.la -luuid -lrt -lcrypt -lpthread -ldl

# make
# make install
# cd /usr/local/apache2/
# ./bin/apachectl -k start

在浏览器中输入
http://127.0.0.1/
如果能够看到
It works!
则表示安装成功
如果是在64位Linux系统上,很多RPM包会有x86_64和i386两个,使用rpm -qa|grep ipaddrxxx类似的命令会查询出两个包:
rpm -qa|grep ipaddr

如果要删除,不可以直接使用:
rpm -e ipaddr

而必须使用:
rpm -e ipaddr.version.arch
[mysql]Table tblName is marked as crashed and should be repaired

Mysql提示tblName表格已损坏,需要修复:
进入到对应的数据库目录:
cd /var/lib/mysql/dbname
使用myisamchk修复:
shell> myisamchk -r tblName

果然有J2ME的Windows Remote Desktop!只不过是商业版。

RDM+™ Remote Desktop for Mobiles allows you to access remotely your desktop or laptop computer from Java powered phone. You can send and receive emails, surf web, edit documents in word processor, copy, cut, paste files or folders and do hundreds other things that you typically do sitting in front of your home or office computer. Interface is user-friendly and navigation is simple.

You can try RDM+ for 7 days absolutely free.

MidpSSH Mobile SSH client

[不指定 2007/05/27 19:33 | by ipaddr ]

以前接触过Java写的SSH客户端,今天突然有想法,想写一个基于J2ME的SSH客户端,在网上搜了一下,发现已经有类似的产品了,真牛B。

MidpSSH is an SSH and Telnet client for MIDP 1.0 / 2.0 (J2ME) devices such as Java(tm)-capable cellphones and other mobile devices. MidpSSH is developed by Karl von Randow www.xk72.com and released under the GPL.

MidpSSH is based upon Floyd SSH and Telnet Floyd by Radek Polak http://phoenix.inf.upol.cz/~polakr/, who ported the Java (tm) Telnet/SSH Applet to the MIDP platform. MidpSSH adds a GUI and a number of other features to Floyd SSH, see the Features section below.

Java(tm) Telnet/SSH Applet is by Matthias L. Jugel, Marcus Meissner javassh.org. It implements SSH1, Telnet and VT320 terminal emulation in Java.

Floyd SSH and Telnet Floyd (and hence MidpSSH) also includes sources from the GNU Classpath project.

MidpSSH 1.2+ includes cryptographic algorithms from The Legion of the Bouncy Castle, modified by Karl von Randow for MIDP. And implementation detail of SSH2 key exchange adapted from Java Secure Channel.

Contribute
There are various ways in which you can contribute to the MidpSSH project. You can help other users, find bugs and suggest enhancements by joining in discussions in the forums. You can join in the Developers forum, download the source code and implement new features or make enhancement

有机会真要试试。

还不知有没有基于J2ME的Windows Remote Desktop?
分页: 32/57 第一页 上页 27 28 29 30 31 32 33 34 35 36 下页 最后页 [ 显示模式: 摘要 | 列表 ]