Programming :: Traverse Through The XML Nodes?
Jul 12, 2011
I have a xml file and I read it within a php file with XML dom. This is the node structure of my xml file :
<Root><name></name>
<surname></surname>
<ID></ID>
<department></department>
[code]....
In the comment line, I've got the parent node of the current node. Parent node is "User" node. I would like to obtain the children of this parent node, say "name","surname " etc. How can I do this? Is there any function such as : "$parent_nodes->bringChildren('name')".
View 1 Replies
ADVERTISEMENT
Jun 16, 2010
I am trying to learn assembly using nasm as assembler. I did not found example related to string operation. I had following example code,
global asm_strlen
section .data
section .bss
section .text
[code].....
my problem is at highlighted line, I am not getting how to copy a byte into 4 byte reg. rather what is syntax of mov instruction to mov byte to WORD DWORD etc.
View 3 Replies
View Related
Mar 16, 2010
I have a cluster script (CentOS 5.4) and I need a UPS for a shutdown. It should look like this ... The first node must wait until the second node has completed several actions and has been completely shut down. So I need a script with a shutdown wait until the other node is ... I was thinking of a test using ping. Alternatively, I would also have an IPMI interface. However, the "pause" may last a maximum of 10 minutes ... Then the wait must be ended.
View 10 Replies
View Related
Oct 14, 2010
When i create a new event device (/dev/input/event) it is automatically grabbed by Xorg:
Code:
(II) config/udev: Adding input device Keypad Emulation Driver (/dev/input/event7)
(**) Keypad Emulation Driver: Applying InputClass "evdev keyboard catchall"
[code]....
View 1 Replies
View Related
Jun 30, 2011
I'm trying to create a script that when given a diretory, it goes traverses through all the subdirectories and process the files in them.However, there is one restriction.directories thatit traverses through must all have a read permission for the others group.How would I go about doing this?
View 1 Replies
View Related
Apr 24, 2010
how can I traverse a directory from Kernel space? I'm using the path_lookup function. However, through the inodes I get with this functions I can only access those files that have been displayed at some point by another process (doing ls from the terminal for example)
View 7 Replies
View Related
May 15, 2011
I need your inputs on performing some operations:-
a. Traverse from top Level directory, find all the directories
b. Rename all these directories to <original name>.dir
c. Once the renaming is done - search from top level and retain only those directories which has .txt content in them.
d. Delete rest all.....
Can i use xargs here to perform operation a and b , or will sed will be useful.
View 14 Replies
View Related
Jan 6, 2010
Since this is my first post, before i describe my problem, i'd like to say regrats to all of you for maintaining here such a good support community.
So, here we go: I have a headless Debian box and i want to set it up as a small office router/gateway. On the box i installed a regular NIC and a Viking Traverse ADSL+ Card which gets recognised by the OS as an 8139 ethernet card and has an embedded ADSL+ modem. The modem is accesible through the PHY interface once it gets assigned an IP. Having said that here is the actual setup:
eth0 : Viking Card
eth1 : NIC (this NIC is connected to a switch)
eth0 : 192.168.1.2 (internal modem is on 192.168.1.1)
eth1 : 192.168.1.3
/etc/network/interfaces
[Code]...
View 1 Replies
View Related
Aug 27, 2010
I can't get sed to actually change the file, clearly there's something basic not working, can anyone point me in the right direction? I know nothing about scripting. Oh yeah, all the directories have spaces which was why so elaborated.
find . -name "*epub" | while read file; do unzip -o "$file" content.opf && mv content.opf content.opf.bak && sed 's/<dc:language>UND</dc:language>/<dc:language xsi:type="dcterms:RFC4646">EN</dc:language>/' < content.opf.bak > content.opf && zip "$file" content.opf && rm -f content.* ; done
View 2 Replies
View Related
Jun 17, 2010
I ise debian lenny on both server and nodes. Nodes are in sence of drbl drbl project.
So, my sendmail on server works well but on nodes in syslog i see:
Code:
Configuration of sendmail on server and nodes is same and it is:
Code:
View 2 Replies
View Related
Oct 22, 2010
How to set the anchor node in NS2? How to define the channel propagation model as Log Normal Shadowing instead of two ray ground reflection model in NS2?
View 2 Replies
View Related
Feb 5, 2010
i want to add keys to the sensor nodes. Hence i want to know whether there is any parameter for key storage in senor nodes
View 1 Replies
View Related
Feb 7, 2011
i need to discover all network nodes and their ips is their a way to do it, then if i need to discover certain nodes which runs certain program. I'm using Fedora14 and FreeBSD
View 2 Replies
View Related
Mar 3, 2010
I'm trying to work with a project manager and some hardware guys and all of us are trying to get a grasp on the UEC.
1. Can a VM span multiple nodes?
2. If a website scales beyond 100% CPU on a node, does it automatically spill over to another node and start using processing power there?
3. Do I have to rewrite the code of my web app (such as WordPress) so that it works in a private cloud?
4. Does KVM support virtual memory such that when I run out of RAM it uses paging?
5. How is UEC any different than me bringing up several servers with several VMs inside, and then moving VMs around as I need? Is it really a cloud where the VMs exist in a cloud, not necessarily a node?
6. If I power off a node while it's hot, how can I assure myself that the data will be okay?
7. Do I want to use SCSI attached RAID, or NAS, or NFS? We're simply trying to host thousands of blogs and LAMP sites in a way that we can handle spike loads.
8. Do I attach the disk volumes to the cluster controller and then run a command such that the nodes can mount those virtual volumes?
9. Do I need to run another command on the VMs to mount volumes that the nodes can see?
10. What is the role of the storage controller and how is it separate from the cluster controller?
11. How many systems, minimum, do we need to get this tested out?
12. For testing purposes, can I install UEC on an Intel P4 server and then a node on Intel P3 server -- even with some limitations?
13. Let's imagine I have 5 node servers, and one catches fire and is a total loss. Can I get those VMs back and get that data back? What would have to be the proper config to make that happen?
View 1 Replies
View Related
Mar 11, 2010
I want to connect two systems in clustering concept. am new for clustering configuration. I have installed ubuntu 9.10 server edition in two system. what do to the next step to configure clustering in ubuntu 9.10 server edition.
View 1 Replies
View Related
Aug 17, 2010
I'm running 10.04 64-bit diskless on ESXi, installed as a minimal virtual machine. I want this server to access an iSCSI drive. The machine can view the iSCSI shares with iscsiadm, and can even log into the drive. When I do an iSCSI login, this appears in /var/log/messages:
Aug 17 11:08:21 ubuntutest kernel: [1123295.329972] scsi4 : iSCSI Initiator over TCP/IP
So, it appears that open-iSCSI is working correctly. But no new /dev/sd* nodes appear, and nothing new appears in /dev/disk/by-path. I'd expect to see /dev/disk/by-path/ip-XXXXXXXXX. fdisk -l shows nothing but the boot drive. My guess is that the "minimal kernel" doesn't include some necessary module or driver.
View 1 Replies
View Related
Mar 10, 2010
I have two Web server (RHEL 5.3) as cluster. i want to get a certificate for website. do i need to get two certificates for a website?
View 2 Replies
View Related
Dec 3, 2010
Are there any prerequisites which much be met in order for udev to create /dev/usb/hiddev* nodes?
I have two Slack 13.0 systems, each connected to a APC UPS via USB, one of which creates a hiddev0 node and the other doesn't. apcupsd can't find the UPS unless this node is present.
The "working" system has been stable in its current configuration for so long that I honestly can't remember if I had to tweak anything in this regard. I've verified that it doesn't use any local udev rules to create this node, and to the best of my knowledge there are no external scripts or processes which would create it either.
The non-working system has a similar configuration - no local rules and/or scripts which touch usb devices or nodes.
View 6 Replies
View Related
Feb 17, 2010
I have an annoying problem with a 2 nodes cluster that I don't understand.
One of my server is totally shutdown.
When I start cman after a reboot on the other server, it hangs on "Starting fencing...". The process which is actually hanging is : /sbin/fence_tool -w -t 300 -m 45 join
When I start this program manually, I get this output :
# /sbin/fence_tool -w -t 300 -m 45 join
Waiting for all 2 nodes to be members
Waiting for all 2 nodes to be members
Waiting for all 2 nodes to be members
Waiting for all 2 nodes to be members
(and so on...)
What I don't understand is why the fence_tool program wait for the 2nd node to join the cluster and don't fence the other node.
Here is my cluster.conf :
<?xml version="1.0"?>
<cluster name="ctpsrv-bdd" config_version="7">
<fence_daemon clean_start="0" post_fail_delay="0" post_join_delay="20"/>
<cman expected_votes="1" two_node="1"/>
[Code]....
Would it be a good idea to edit the cman startup script and remove the "-w" option of command fence_tool join, so the command do not hang up ?
View 4 Replies
View Related
Sep 16, 2009
I'm putting a server together and have run into a boot up problem. (I thought about putting this in the server forum, but it might be a more generic problem that others have seen and know how to rectify.) The install seems to have gone just fine. I have the /boot partition on an internal IDE drive. The rest of that drive and another are mirrored in a Raid0 configuration (using the Linux software to do that) for data storage. The swap partition is a part of the Raid5 SCSI array that also has the / (root) partition on it.
After installation it would not finish the booting process. I suspected that GRUB didn't like all the Raid arrays and such, but it seems to be fine. I can say that because the machine will boot into rescue mode with the GUI splash screen and I have access to the whole directory tree. I have already searched on-line and following prudent advice, ran the yum update while in the chroot /mnt/sysimage mode. That only took overnight to download and most of this morning to complete. Still no dice. Used vim to delete the rhgb quiet commands in the grub.conf file so I could see where the kernel seems to be hanging.
So right after the "Creating initial device nodes" is a line about my generic PS2 wheel mouse. So I tried a USB mouse. Got more output so tried swapping out to a USB keyboard. Got a little further with more information about input devices, but still stops. Also, I tried a PCI video card just to make sure the onboard video wasn't the problem - no change. So, if someone in the Fedora community knows what loads up or is configured right after the mouse and keyboard, I might be able to figure out what's causing the computer to hang during the boot process.
View 2 Replies
View Related
Jun 22, 2011
I'm having a problem with NFS. I'm trying to mount /home, which is on the server, to the client nodes. The server is currently running FC14 (64 bit) and I'm in the process of updating all the clients nodes to the same OS. Currently, all the client nodes are running FC8 (32 bit) and are capable of mounting /home on the server. However, the one client node that I have updated to FC14 is having problems mounting /home. I can ssh to the node with no problem however I get the following message:
Could not chdir to home directory /home/myuserid: Permission denied. Now, if I excute the following command: "sudo mount -a" I get no errors and now I can see my home directory.
View 9 Replies
View Related
Dec 3, 2009
I am deciding to whether use OSPF or RIPv2 on my network. The key point for me is how good each of them are in dynamically adding and removing nodes. I am pretty sure that OSPF works well if a node is suddenly dropped or a new one is introduced( Please correct me if I am wrong). how good RIPv2 is at this.
View 1 Replies
View Related
Aug 17, 2010
I use Slackware 13.0. I just upgraded from 2.6.32 to 2.6.35. On 2.6.35, the kernel supplying strange non-existant node like hda* and many symlink like cdr cdr0 cdrom cdrom0 etc. Well, i use libata and disable the old ATA driver, so my HDD should only be displayed as sd**. Also, i've checked all the udev rules, and i don't see any SYMLINK entries that would produce that cdr cdr0 links. My 2.6.32 and 2.6.35 config are identical. Everything were working normally on 2.6.32. Btw, i've tried to upgrade to 13.1. Then boot the standard huge.smp kernel. The same problem occured too. And with other problem i get with 13.1, i decided to downgrade to 13.0.
View 2 Replies
View Related
Dec 3, 2010
As I was updating machines today, I was wondering... Is there some way to cache the RPM files locally that yum is grabbing? Like many, I have a number of VMs I run, and it most updates are the same between the nodes. I'm guessing I'd need some sort of http cache? Just looking for pointers, not sure what I'm looking for, however.
View 4 Replies
View Related
Jun 23, 2010
Now that Ubuntu is at a LTS stage with Lucid and is easier to install PV in XenServer, I have been wanting to drop my current debian VM nodes in favor of Ubuntu 10.04. So far I have DRBD8 and OCFS2 all working nicely as primary/primary and I am on the next stage of my setup by installing ldirectord and heartbeat. Can anyone shed some light on heartbeat-gui (hb_gui) as it no longer seems to be in the repositories (since Jaunty)?[URL].. I understand that Lucid now uses pacemaker as part of a clustering suite but I have no idea if I really need it. I really liked being able to run hb_gui and logging into the heartbeat cluster to manage resources via point and click so if anyone has any hints on replacements or newer preferred methods to accomplish the same tasks via point-n-click,
View 1 Replies
View Related
Jul 1, 2010
I am setting up a computing cluster in my lab, as below. all the "eth0" IP addresses are static (for cluster communication) and the "eth1" of the front node is the only one connected to the internet through lab's DHCP server (which is connected to a centralized computer center in the university). The thing I wish to do is to do some sort of IP masquerading to enable all the nodes to have internet access. I actually google around and read some books. The similar things I came across is setting rules in iptables but I did not manage to get any of them working. I am using Ubuntu Lucid 64-bit on all machine.
View 6 Replies
View Related
Jan 24, 2011
I have a 8 core computer, which has 8 logical processor in total. I want to create 8 process(nodes). Each node is mapped to each logical processor. The order is code...
I wrote the code as below, could you please see whether it is correct? code...
View 3 Replies
View Related
Apr 15, 2010
I'm a starter here in linux, I have written a driver code and in that, I register my character devices by passing 0 for the major number.
To set up I used to use mknod command from terminal to create node,
Is there any method to create node dynamically from driver code during initialization and delete them at cleanup time?
View 1 Replies
View Related
May 28, 2010
I am trying to setup Rocks Cluster on a Cluster containing 1 Master node and 23 slave nodes connected via a Switch. The master node's eth1 is connected to public IP and eth0 is connected to the slave nodes via the switch.
I was able to install the Rocks cluster on the machine, I configured the IP for master through DHCP. When I run the command 'insert-ethers' on the master node, it doesnot get me any slave nodes.
setting up the Rocks cluster on all the nodes?
View 1 Replies
View Related
Apr 7, 2011
I want to simulate a wireless network where all nodes broadcast packets
View 3 Replies
View Related