How to properly execute script on shutdown using systemd

Hello,
I am trying to execute a simple script to update my freedns.afraid.org DNS record on each machine shutdown. Could somebody please provide me a complete step by step example on how to achieve this? There are many posts, but none work, directory structure is always different, and there are no results. Below is my current directory structure:
[kbs1@arch ~]$ cd /etc/systemd/
[kbs1@arch systemd]$ ll
total 40
drwxr-xr-x 5 root root 4096 Nov 1 06:55 .
drwxr-xr-x 75 root root 4096 Nov 15 01:07 ..
-rw-r--r-- 1 root root 529 May 30 14:55 bootchart.conf
-rw-r--r-- 1 root root 770 Oct 2 14:01 journald.conf
-rw-r--r-- 1 root root 709 Oct 2 14:01 logind.conf
drwxr-xr-x 2 root root 4096 May 30 14:55 ntp-units.d
drwxr-xr-x 7 root root 4096 Nov 18 13:24 system
-rw-r--r-- 1 root root 1033 Oct 2 14:01 system.conf
drwxr-xr-x 2 root root 4096 May 30 14:55 user
-rw-r--r-- 1 root root 468 Oct 2 14:01 user.conf
[kbs1@arch systemd]$ ll user
total 8
drwxr-xr-x 2 root root 4096 May 30 14:55 .
drwxr-xr-x 5 root root 4096 Nov 1 06:55 ..
[kbs1@arch systemd]$ ll system
total 28
drwxr-xr-x 7 root root 4096 Nov 18 13:24 .
drwxr-xr-x 5 root root 4096 Nov 1 06:55 ..
lrwxrwxrwx 1 root root 39 Sep 22 00:47 dbus-uk.org.thekelleys.dnsmasq -> /usr/lib/systemd/system/dnsmasq.service
drwxr-xr-x 2 root root 4096 Jul 11 23:47 [email protected]
drwxr-xr-x 2 root root 4096 Jul 8 06:16 getty.target.wants
drwxr-xr-x 2 root root 4096 Nov 1 06:55 multi-user.target.wants
drwxr-xr-x 2 root root 4096 Jul 20 00:45 printer.target.wants
drwxr-xr-x 2 root root 4096 Jul 20 00:45 sockets.target.wants
[kbs1@arch systemd]$ cd /usr/lib
lib/ lib64/
[kbs1@arch systemd]$ cd /usr/lib
lib/ lib64/
[kbs1@arch systemd]$ cd /usr/lib/sys
sysctl.d/ systemd/
[kbs1@arch systemd]$ cd /usr/lib/systemd/
catalog/ systemd-hostnamed systemd-shutdown
ntp-units.d/ systemd-initctl systemd-shutdownd
scripts/ systemd-journald systemd-sleep
system/ systemd-journal-gatewayd systemd-sysctl
systemd systemd-localed systemd-timedated
systemd-ac-power systemd-logind systemd-udevd
systemd-activate systemd-machined systemd-update-utmp
systemd-backlight systemd-modules-load systemd-user-sessions
systemd-binfmt systemd-multi-seat-x systemd-vconsole-setup
systemd-bootchart systemd-quotacheck system-generators/
systemd-cgroups-agent systemd-random-seed system-shutdown/
systemd-coredump systemd-readahead system-sleep/
systemd-cryptsetup systemd-remount-fs user/
systemd-fsck systemd-reply-password user-generators/
[kbs1@arch systemd]$ cd /usr/lib/systemd/
[kbs1@arch systemd]$ ll user
total 20
drwxr-xr-x 2 root root 4096 Nov 18 13:39 .
drwxr-xr-x 11 root root 4096 Nov 18 13:37 ..
lrwxrwxrwx 1 root root 40 Oct 21 15:27 bluetooth.target -> /usr/lib/systemd/system/bluetooth.target
-rw-r--r-- 1 root root 373 Oct 21 15:27 default.target
-rw-r--r-- 1 root root 499 Oct 21 15:27 exit.target
lrwxrwxrwx 1 root root 36 Oct 21 15:27 paths.target -> /usr/lib/systemd/system/paths.target
lrwxrwxrwx 1 root root 38 Oct 21 15:27 printer.target -> /usr/lib/systemd/system/printer.target
lrwxrwxrwx 1 root root 39 Oct 21 15:27 shutdown.target -> /usr/lib/systemd/system/shutdown.target
lrwxrwxrwx 1 root root 40 Oct 21 15:27 smartcard.target -> /usr/lib/systemd/system/smartcard.target
lrwxrwxrwx 1 root root 38 Oct 21 15:27 sockets.target -> /usr/lib/systemd/system/sockets.target
lrwxrwxrwx 1 root root 36 Oct 21 15:27 sound.target -> /usr/lib/systemd/system/sound.target
-rw-r--r-- 1 root root 501 Oct 21 15:27 systemd-exit.service
lrwxrwxrwx 1 root root 37 Oct 21 15:27 timers.target -> /usr/lib/systemd/system/timers.target
[kbs1@arch systemd]$ ll system
total 856
drwxr-xr-x 10 root root 12288 Nov 1 06:56 .
drwxr-xr-x 11 root root 4096 Nov 18 13:37 ..
-rw-r--r-- 1 root root 428 Jul 29 11:49 alsa-restore.service
-rw-r--r-- 1 root root 481 Jul 29 11:49 alsa-state.service
-rw-r--r-- 1 root root 372 Jul 29 11:49 alsa-store.service
lrwxrwxrwx 1 root root 14 Oct 21 15:27 [email protected] -> [email protected]
-rw-r--r-- 1 root root 1042 Oct 31 17:31 avahi-daemon.service
-rw-r--r-- 1 root root 874 Oct 31 17:31 avahi-daemon.socket
-rw-r--r-- 1 root root 975 Oct 31 17:31 avahi-dnsconfd.service
-rw-r--r-- 1 root root 546 Oct 21 15:27 basic.target
drwxr-xr-x 2 root root 4096 Aug 7 16:14 basic.target.wants
-rw-r--r-- 1 root root 379 Oct 21 15:27 bluetooth.target
-rw-r--r-- 1 root root 296 Jul 23 16:00 colord.service
-rw-r--r-- 1 root root 699 Oct 21 15:27 console-getty.service
-rw-r--r-- 1 root root 722 Oct 21 15:27 console-shell.service
-rw-r--r-- 1 root root 194 Jun 23 11:17 cronie.service
-rw-r--r-- 1 root root 366 Oct 21 15:27 cryptsetup.target
lrwxrwxrwx 1 root root 13 Oct 21 15:27 ctrl-alt-del.target -> reboot.target
-rw-r--r-- 1 root root 224 Oct 30 15:59 cups-browsed.service
lrwxrwxrwx 1 root root 12 Oct 25 21:12 cupsd.service -> cups.service
-rw-r--r-- 1 root root 126 Oct 25 21:12 cups.path
-rw-r--r-- 1 root root 158 Oct 25 21:12 cups.service
-rw-r--r-- 1 root root 127 Oct 25 21:12 cups.socket
lrwxrwxrwx 1 root root 25 Oct 21 15:27 dbus-org.freedesktop.hostname1.service -> systemd-hostnamed.service
lrwxrwxrwx 1 root root 23 Oct 21 15:27 dbus-org.freedesktop.locale1.service -> systemd-localed.service
lrwxrwxrwx 1 root root 22 Oct 21 15:27 dbus-org.freedesktop.login1.service -> systemd-logind.service
lrwxrwxrwx 1 root root 24 Oct 21 15:27 dbus-org.freedesktop.machine1.service -> systemd-machined.service
lrwxrwxrwx 1 root root 25 Oct 21 15:27 dbus-org.freedesktop.timedate1.service -> systemd-timedated.service
-rw-r--r-- 1 root root 353 Oct 12 16:22 dbus.service
-rw-r--r-- 1 root root 102 Oct 12 16:22 dbus.socket
drwxr-xr-x 2 root root 4096 Nov 1 06:55 dbus.target.wants
-rw-r--r-- 1 root root 978 Oct 21 15:27 debug-shell.service
lrwxrwxrwx 1 root root 16 Oct 21 15:27 default.target -> graphical.target
-rw-r--r-- 1 root root 156 Aug 25 09:57 deluged.service
-rw-r--r-- 1 root root 145 Aug 25 09:57 deluge-web.service
-rw-r--r-- 1 root root 636 Oct 21 15:27 dev-hugepages.mount
-rw-r--r-- 1 root root 590 Oct 21 15:27 dev-mqueue.mount
-rw-r--r-- 1 root root 227 Aug 3 17:20 dhcpcd.service
-rw-r--r-- 1 root root 318 Aug 3 17:20 [email protected]
-rw-r--r-- 1 root root 305 Oct 23 19:30 dmeventd.service
-rw-r--r-- 1 root root 243 Oct 23 19:30 dmeventd.socket
-rw-r--r-- 1 root root 383 Oct 30 16:17 dnsmasq.service
-rw-r--r-- 1 root root 940 Oct 21 15:27 emergency.service
-rw-r--r-- 1 root root 431 Oct 21 15:27 emergency.target
-rw-r--r-- 1 root root 149 May 29 05:46 fancontrol.service
-rw-r--r-- 1 root root 440 Oct 21 15:27 final.target
-rw-r--r-- 1 root root 141 Sep 12 06:38 ftpd.service
-rw-r--r-- 1 root root 1486 Oct 21 15:27 [email protected]
-rw-r--r-- 1 root root 460 Oct 21 15:27 getty.target
-rw-r--r-- 1 root root 253 Oct 29 01:28 [email protected]
-rw-r--r-- 1 root root 112 Oct 29 01:28 git-daemon.socket
-rw-r--r-- 1 root root 161 Oct 24 19:10 gpm.service
-rw-r--r-- 1 root root 522 Oct 21 15:27 graphical.target
-rw-r--r-- 1 root root 487 Oct 21 15:27 halt.target
-rw-r--r-- 1 root root 199 May 29 05:46 healthd.service
-rw-r--r-- 1 root root 447 Oct 21 15:27 hibernate.target
-rw-r--r-- 1 root root 337 Jul 18 21:07 httpd.service
-rw-r--r-- 1 root root 468 Oct 21 15:27 hybrid-sleep.target
-rw-r--r-- 1 root root 596 Oct 21 15:27 initrd-cleanup.service
-rw-r--r-- 1 root root 536 Oct 21 15:27 initrd-fs.target
-rw-r--r-- 1 root root 763 Oct 21 15:27 initrd-parse-etc.service
-rw-r--r-- 1 root root 509 Oct 21 15:27 initrd-root-fs.target
-rw-r--r-- 1 root root 606 Oct 21 15:27 initrd-switch-root.service
-rw-r--r-- 1 root root 691 Oct 21 15:27 initrd-switch-root.target
-rw-r--r-- 1 root root 654 Oct 21 15:27 initrd.target
-rw-r--r-- 1 root root 668 Oct 21 15:27 initrd-udevadm-cleanup-db.service
-rw-r--r-- 1 root root 319 Jun 1 07:35 ip6tables.service
-rw-r--r-- 1 root root 308 Jun 1 07:35 iptables.service
-rw-r--r-- 1 root root 162 Oct 14 08:42 irexec.service
-rw-r--r-- 1 root root 501 Oct 21 15:27 kexec.target
-rw-r--r-- 1 root root 721 Oct 21 15:27 kmod-static-nodes.service
-rw-r--r-- 1 root root 137 Jun 10 08:46 krb5-kadmind.service
-rw-r--r-- 1 root root 129 Jun 10 08:46 krb5-kdc.service
-rw-r--r-- 1 root root 128 Jun 10 08:46 krb5-kpropd.service
-rw-r--r-- 1 root root 159 Jun 10 08:46 [email protected]
-rw-r--r-- 1 root root 122 Jun 10 08:46 krb5-kpropd.socket
-rw-r--r-- 1 root root 177 Oct 14 08:42 lircm.service
-rw-r--r-- 1 root root 225 Oct 14 08:42 lirc.service
-rw-r--r-- 1 root root 348 May 29 05:46 lm_sensors.service
-rw-r--r-- 1 root root 395 Oct 21 15:27 local-fs-pre.target
-rw-r--r-- 1 root root 489 Oct 21 15:27 local-fs.target
drwxr-xr-x 2 root root 4096 Nov 1 06:55 local-fs.target.wants
-rw-r--r-- 1 root root 332 Oct 23 19:30 lvmetad.service
-rw-r--r-- 1 root root 239 Oct 23 19:30 lvmetad.socket
-rw-r--r-- 1 root root 504 Oct 23 19:30 lvm-monitoring.service
-rw-r--r-- 1 root root 277 Sep 13 15:11 lxdm.service
-rw-r--r-- 1 root root 405 Oct 21 15:27 machine.slice
-rw-r--r-- 1 root root 130 Sep 4 16:24 mdadm.service
-rw-r--r-- 1 root root 524 Oct 21 15:27 multi-user.target
drwxr-xr-x 2 root root 4096 Nov 1 06:55 multi-user.target.wants
-rw-r--r-- 1 root root 264 Sep 24 14:50 mysqld.service
-rw-r--r-- 1 root root 404 Aug 6 10:46 [email protected]
-rw-r--r-- 1 root root 317 Aug 6 10:46 [email protected]
-rw-r--r-- 1 root root 238 Aug 6 10:46 netctl.service
-rw-r--r-- 1 root root 290 Aug 6 10:46 [email protected]
-rw-r--r-- 1 root root 248 Aug 6 10:46 netctl-sleep.service
-rw-r--r-- 1 root root 443 Oct 21 15:27 network-online.target
-rw-r--r-- 1 root root 433 Oct 21 15:27 network.target
-rw-r--r-- 1 root root 400 Oct 25 17:29 nscd.service
-rw-r--r-- 1 root root 514 Oct 21 15:27 nss-lookup.target
-rw-r--r-- 1 root root 473 Oct 21 15:27 nss-user-lookup.target
-rw-r--r-- 1 root root 207 Aug 1 05:29 ntpdate.service
-rw-r--r-- 1 root root 210 Aug 1 05:29 ntpd.service
-rw-r--r-- 1 root root 354 Oct 21 15:27 paths.target
-rw-r--r-- 1 root root 172 Sep 18 19:20 polkit.service
-rw-r--r-- 1 root root 287 Sep 6 04:01 postfix.service
-rw-r--r-- 1 root root 500 Oct 21 15:27 poweroff.target
-rw-r--r-- 1 root root 377 Oct 21 15:27 printer.target
-rw-r--r-- 1 root root 693 Oct 21 15:27 proc-sys-fs-binfmt_misc.automount
-rw-r--r-- 1 root root 603 Oct 21 15:27 proc-sys-fs-binfmt_misc.mount
-rw-r--r-- 1 root root 641 Oct 21 15:27 quotaon.service
-rw-r--r-- 1 root root 493 Oct 21 15:27 reboot.target
-rw-r--r-- 1 root root 396 Oct 21 15:27 remote-fs-pre.target
-rw-r--r-- 1 root root 482 Oct 21 15:27 remote-fs.target
-rw-r--r-- 1 root root 958 Oct 21 15:27 rescue.service
-rw-r--r-- 1 root root 486 Oct 21 15:27 rescue.target
-rw-r--r-- 1 root root 500 Oct 21 15:27 rpcbind.target
-rw-r--r-- 1 root root 127 Oct 28 17:58 [email protected]
-rw-r--r-- 1 root root 115 Oct 28 17:58 saned.socket
-rw-r--r-- 1 root root 158 May 29 05:46 sensord.service
-rw-r--r-- 1 root root 989 Oct 21 15:27 [email protected]
-rw-r--r-- 1 root root 402 Oct 21 15:27 shutdown.target
drwxr-xr-x 2 root root 4096 Oct 7 05:47 shutdown.target.wants
-rw-r--r-- 1 root root 362 Oct 21 15:27 sigpwr.target
-rw-r--r-- 1 root root 420 Oct 21 15:27 sleep.target
-rw-r--r-- 1 root root 403 Oct 21 15:27 -.slice
-rw-r--r-- 1 root root 409 Oct 21 15:27 slices.target
-rw-r--r-- 1 root root 380 Oct 21 15:27 smartcard.target
-rw-r--r-- 1 root root 279 Aug 11 18:43 smartd.service
-rw-r--r-- 1 root root 266 Aug 17 12:20 snmpd.service
-rw-r--r-- 1 root root 283 Aug 17 12:20 snmptrapd.service
-rw-r--r-- 1 root root 356 Oct 21 15:27 sockets.target
drwxr-xr-x 2 root root 4096 Nov 1 06:56 sockets.target.wants
-rw-r--r-- 1 root root 380 Oct 21 15:27 sound.target
-rw-r--r-- 1 root root 221 Oct 27 01:00 speech-dispatcherd.service
-rw-r--r-- 1 root root 511 Sep 13 11:00 sshdgenkeys.service
-rw-r--r-- 1 root root 410 Sep 13 11:00 sshd.service
-rw-r--r-- 1 root root 156 Sep 13 11:00 [email protected]
-rw-r--r-- 1 root root 128 Sep 13 11:00 sshd.socket
-rw-r--r-- 1 root root 441 Oct 21 15:27 suspend.target
-rw-r--r-- 1 root root 270 Sep 13 05:38 svnserve.service
-rw-r--r-- 1 root root 353 Oct 21 15:27 swap.target
-rw-r--r-- 1 root root 681 Oct 21 15:27 sys-fs-fuse-connections.mount
-rw-r--r-- 1 root root 540 Oct 21 15:27 sysinit.target
drwxr-xr-x 2 root root 4096 Nov 1 06:55 sysinit.target.wants
-rw-r--r-- 1 root root 685 Oct 21 15:27 sys-kernel-config.mount
-rw-r--r-- 1 root root 628 Oct 21 15:27 sys-kernel-debug.mount
-rw-r--r-- 1 root root 1235 Oct 21 15:27 syslog.socket
-rw-r--r-- 1 root root 646 Oct 21 15:27 systemd-ask-password-console.path
-rw-r--r-- 1 root root 657 Oct 21 15:27 systemd-ask-password-console.service
-rw-r--r-- 1 root root 574 Oct 21 15:27 systemd-ask-password-wall.path
-rw-r--r-- 1 root root 689 Oct 21 15:27 systemd-ask-password-wall.service
-rw-r--r-- 1 root root 784 Oct 21 15:27 [email protected]
-rw-r--r-- 1 root root 1015 Oct 21 15:27 systemd-binfmt.service
-rw-r--r-- 1 root root 696 Oct 21 15:27 systemd-fsck-root.service
-rw-r--r-- 1 root root 656 Oct 21 15:27 [email protected]
-rw-r--r-- 1 root root 548 Oct 21 15:27 systemd-halt.service
-rw-r--r-- 1 root root 505 Oct 21 15:27 systemd-hibernate.service
-rw-r--r-- 1 root root 642 Oct 21 15:27 systemd-hostnamed.service
-rw-r--r-- 1 root root 523 Oct 21 15:27 systemd-hybrid-sleep.service
-rw-r--r-- 1 root root 484 Oct 21 15:27 systemd-initctl.service
-rw-r--r-- 1 root root 489 Oct 21 15:27 systemd-initctl.socket
-rw-r--r-- 1 root root 940 Oct 21 15:27 systemd-journald.service
-rw-r--r-- 1 root root 833 Oct 21 15:27 systemd-journald.socket
-rw-r--r-- 1 root root 702 Oct 21 15:27 systemd-journal-flush.service
-rw-r--r-- 1 root root 582 Oct 21 15:27 systemd-journal-gatewayd.service
-rw-r--r-- 1 root root 406 Oct 21 15:27 systemd-journal-gatewayd.socket
-rw-r--r-- 1 root root 561 Oct 21 15:27 systemd-kexec.service
-rw-r--r-- 1 root root 591 Oct 21 15:27 systemd-localed.service
-rw-r--r-- 1 root root 972 Oct 21 15:27 systemd-logind.service
-rw-r--r-- 1 root root 667 Oct 21 15:27 systemd-machined.service
-rw-r--r-- 1 root root 1029 Oct 21 15:27 systemd-modules-load.service
-rw-r--r-- 1 root root 478 Oct 21 15:27 [email protected]
-rw-r--r-- 1 root root 557 Oct 21 15:27 systemd-poweroff.service
-rw-r--r-- 1 root root 688 Oct 21 15:27 systemd-quotacheck.service
-rw-r--r-- 1 root root 777 Oct 21 15:27 systemd-random-seed.service
-rw-r--r-- 1 root root 845 Oct 21 15:27 systemd-readahead-collect.service
-rw-r--r-- 1 root root 615 Oct 21 15:27 systemd-readahead-done.service
-rw-r--r-- 1 root root 593 Oct 21 15:27 systemd-readahead-done.timer
-rw-r--r-- 1 root root 555 Oct 21 15:27 systemd-readahead-drop.service
-rw-r--r-- 1 root root 757 Oct 21 15:27 systemd-readahead-replay.service
-rw-r--r-- 1 root root 552 Oct 21 15:27 systemd-reboot.service
-rw-r--r-- 1 root root 828 Oct 21 15:27 systemd-remount-fs.service
-rw-r--r-- 1 root root 479 Oct 21 15:27 systemd-shutdownd.service
-rw-r--r-- 1 root root 528 Oct 21 15:27 systemd-shutdownd.socket
-rw-r--r-- 1 root root 501 Oct 21 15:27 systemd-suspend.service
-rw-r--r-- 1 root root 900 Oct 21 15:27 systemd-sysctl.service
-rw-r--r-- 1 root root 593 Oct 21 15:27 systemd-timedated.service
-rw-r--r-- 1 root root 853 Oct 21 15:27 systemd-tmpfiles-clean.service
-rw-r--r-- 1 root root 450 Oct 21 15:27 systemd-tmpfiles-clean.timer
-rw-r--r-- 1 root root 622 Oct 21 15:27 systemd-tmpfiles-setup-dev.service
-rw-r--r-- 1 root root 915 Oct 21 15:27 systemd-tmpfiles-setup.service
-rw-r--r-- 1 root root 578 Oct 21 15:27 systemd-udevd-control.socket
-rw-r--r-- 1 root root 575 Oct 21 15:27 systemd-udevd-kernel.socket
-rw-r--r-- 1 root root 772 Oct 21 15:27 systemd-udevd.service
-rw-r--r-- 1 root root 827 Oct 21 15:27 systemd-udev-settle.service
-rw-r--r-- 1 root root 723 Oct 21 15:27 systemd-udev-trigger.service
-rw-r--r-- 1 root root 761 Oct 21 15:27 systemd-update-utmp-runlevel.service
-rw-r--r-- 1 root root 831 Oct 21 15:27 systemd-update-utmp.service
-rw-r--r-- 1 root root 558 Oct 21 15:27 systemd-user-sessions.service
-rw-r--r-- 1 root root 690 Oct 21 15:27 systemd-vconsole-setup.service
-rw-r--r-- 1 root root 433 Oct 21 15:27 system.slice
-rw-r--r-- 1 root root 652 Oct 21 15:27 system-update.target
-rw-r--r-- 1 root root 355 Oct 21 15:27 timers.target
drwxr-xr-x 2 root root 4096 Nov 1 06:55 timers.target.wants
-rw-r--r-- 1 root root 509 Oct 21 15:27 time-sync.target
-rw-r--r-- 1 root root 591 Oct 21 15:27 tmp.mount
-rw-r--r-- 1 root root 155 May 17 2013 udisks.service
-rw-r--r-- 1 root root 417 Oct 21 15:27 umount.target
-rw-r--r-- 1 root root 584 Oct 21 15:27 [email protected]
-rw-r--r-- 1 root root 392 Oct 21 15:27 user.slice
-rw-r--r-- 1 root root 202 Oct 21 16:31 uuidd.service
-rw-r--r-- 1 root root 126 Oct 21 16:31 uuidd.socket
-rw-r--r-- 1 root root 221 Oct 29 22:58 vboxweb.service
-rw-r--r-- 1 root root 160 May 12 2013 vsftpd.service
-rw-r--r-- 1 root root 163 May 12 2013 [email protected]
-rw-r--r-- 1 root root 104 May 12 2013 vsftpd.socket
-rw-r--r-- 1 root root 201 May 12 2013 vsftpd-ssl.service
-rw-r--r-- 1 root root 226 May 12 2013 [email protected]
-rw-r--r-- 1 root root 105 May 12 2013 vsftpd-ssl.socket
-rw-r--r-- 1 root root 349 Sep 30 11:32 xmms2d.service
[kbs1@arch systemd]$
Could someone tell me which file to create, exactly where, and what symlink to link to it? Also, what commands to type then? I just want to execute these simple commands:
echo "Updating dynamic IP at freedns.afraid.org..."
wget -qO- http://freedns.afraid.org/dynamic/update.php?YYY &> /dev/null
Thank you very much! I'm sure this will help others as well.

Start by reading systemd.unit(5) and systemd.service(5)

Similar Messages

  • How to properly configure a home network using both Mac and PC computers

    Is there a book or set of guidelines that can tell me how to properly configure (exact specifications) my computers in a home network? Here is what I am trying to do and using:
    1) Three computers: iMac (late 06 ver), Macbook (newest version), Dell laptop. The two Macs are using Leopard and the PC is XP.
    2) Bellsouth modem which feeds into the Airport Extreme Base Station (AEBS)
    3) The AEBS has a USB hub which is connected to a external hard drive and two inkjet printers. A third laser printer/scanner/fax machine is connected to the AEBS via ethernet.
    4) All three computers use a wireless connection to the AEBS.
    I would like the following:
    1) Have a secured and password driven network - don't want outsiders connecting to the nework without permission.
    2) All computers to be able to access the USB printers and ext HD.
    3) The two Macs to read/write to each other with password access
    4) The iMac to have read/write capabalities over the PC via VSFusion or Bootcamp if possible.
    Currently, all three have Internet access via the AEBS and can print on the ethernet printer. Both Macs can see the Bonjour USB printers and print (however they to do not display on the AEBS configuration display utility and neither does the ext HD). The USB ext HD is shown on the iMac desktop and I have access to it, but does not display on the MacBook. I have not checked if the PC sees the external HD and it really does not matter if it ever does, although it would be nice.
    I am hoping that there is some standard configuration that I can "cut and paste" that is generally used to allow a home network to share resources while still being secure.
    Any advice and help is greatly appreciated.
    Thanks,
    Andrew

    Andrew,
    What you would like is fairly complicated so this will probably be a lengthy post, but hopefully I can assist you.
    As others here have pointed out, networks can vary widely, but the best networks have one element in common: planning. The first thing you need to think about is how you would like all of these systems to cooperate. For instance, do you want one of the machines to serve files to the others and be a central repository, or are you just interested in having them share documents on occasion so that you don't have to carry around, say, a USB key all the time? That said, here is a basic list of things I think you should look into.
    1. Network Basics
    First step is to get your local network set up. I'd go for WPA or WPA2 wireless security as they are relatively strong standards and you can use human-readable passwords. Additionally, unless you have an explicit need for someone outside your network to initialize a connection (Windows' RDP for instance), do not allow any passthroughs or port redirects on your AEBS.
    2. Network Topology
    Decide how you want computers and networked devices to identify themselves and their relative locations in the network: in short, do you want static ip's or dynamic ip's? Most of the time, static IP's can be assigned on a DHCP router, the trick is to assign the statics higher than your number of devices (or lower on some routers - for instance Linksys routers start DHCP at 192.168.1.100 but you could have statics from 192.168.1.2 to 192.168.1.99). For instance, it is impractical to set a laptop to static because I'm often in coffee shoppes and other environments that assign via DHCP; on the other hand, it's a good idea to have a printer be static so that you always know where to find it. So, I have 10.0.1.x network (default on AEBS), and the printer is 10.0.1.24, since the likelihood of my encountering an IP conflict with 4 computers on the subnet is virtually zero. If you configure a static device behind your AEBS, defaults are usually
    Default Gateway 10.0.1.1
    IP Address 10.0.1.(your choice)
    Subnet Mask 255.255.255.0
    3. File-sharing.
    3a) Mac OS X has a built-in SMB/CIFS (Windows file & printer sharing protocol) client, and a basic SMB [samba] server can be enabled in the sharing preference panel (enable file and/or printer sharing). Windows XP can use these shares, but must authenticate. For that reason, you may not be able to see your shares in the Network Places browser, however you should be able to get to them by mapping the network drive (tools menu) or executing RUN with \\computer.name\share.name. You will then be able to type in your credentials. I would also suggest relatively simple names for the Macs in question (set in Sharing preference pane). Typing Andrew's-iMac-G4 in every time you want to find it will get irritating after a while to say the least, especially if you need to troubleshoot.
    3b) The reverse works similarly. You can Connect to Server... from Finder to get to the Windows shares. To do this you must have Windows File and Printer sharing enabled (most easily through the Network Setup Wizard in Control Panels - Use Classic View). It's really easy if your account names and passwords are identical on the Mac and PC, because when loading user profiles, the Mac will generally automatically try to authenticate against the Windows machine with your Mac logon credentials. (Windows seems to do this against the Mac as well) You can write an Applescript or there are some PLIST modifications you can make to mount Windows shares at login.
    4. Printing
    I'm not exactly sure what you had in mind here since I'm not sure what's connected to which computer or directly to the network. If it is possible, I personally find putting my printers directly on the network to be the easiest thing. Especially if printing large PDF or graphics files, the spooling on the host system can really slow the computer down, and slow down printing. For example, I used to have a laserjet on a Windows box and had to print a very large file. Going through a Win print server, it only printed a page every 30 seconds, but when I got a jetdirect adapter, the whole thing was done in under two minutes. If you have HP Printers, I would recommend the jetdirect print servers (I have used with both a laserjet and a supposedly unsupported color inkjet).

  • How can i execute multiple database operations using multiple objects

    i have data in files which i need to read/parse and insert/update the database. can someone tell me how can i read multiple statements at a time and process using multiple objects.

    This doesn't seem like too much of a JDBC question or at least the answer as I see it isn't unique or specific to JDBC.
    If you want to run multiple processes within your single program then you need to use Java threads. I would recommend you read up on how to properly code Java threads and if you have questions unique to your multi-threaded JDBC implementation come back and ask those questions.
    You may also want tot take advantage of a transaction manager that includes a database connection pool that will handle most of the complexity for you. Depending on the flexibility of your architecture you may not have to do any thread coding at all when using a transaction manager.

  • How to create executable jar in eclipse using linking in compiler

    Hi,
    I have a project in Eclipse. I wrote already an ant build file for creating an executable jar which includes all project files.
    Now I want to create a second executable jar which is a subset of the project (a limited number of classes are necessary).
    I have a main class and I was looking for a way to generate a jar file which includes the main class and all the depending classes.
    Is there a way to do it? With ant or with another tool?
    Is it possible to compile a project given a main class, and include all depending classes?
    Regards,
    Biebel
    Edited by: biebel1975 on Jan 7, 2009 10:21 AM

    biebel1975 wrote:
    Some more information:
    When I compile all the classes, the jar file is +/- 3.5Mb inclusive the server side logic.
    The subproject I want to build, should be less then 1Mb (Only some screens and beans, no business logic ((only +/- 10% of the projects code) )).
    My question is: How can I create a executable jar with only the necessary class files which depends on the main class. (Linked with the imports).
    Is there a tool to do that? Can it be done with an ANT script? If so, how does the script looks?
    What are you talking about?
    You already said that you are using Ant.
    Ant uses script files.
    Since you have one with X items in it and you want something new with X-Y items in it the obviously it would make sense to construct an ant script that does less than the other ant script.
    The following provides a huge amount of information about Ant.
    [http://ant.apache.org/resources.html]
    Other than that no one can tell you want your Ant script will look like except that it will do less than the one that you already have.

  • How to dynamically execute generated SQL statements using 11gR2 ?

    Hello,
    I'd like to know if it is possible to do what the following statement intended to do:
    select * from (select replace('select empno from emp',
                                 '') from dual);in other words, is it possible to dynamically generate and execute a select statement in a from clause ?
    thank you for your help,
    John
    Edited by: 440bx on Jul 16, 2010 3:57 PM changed "generate" to "generated" in subject

    Hello Aketi,
    That is totally WICKED !!
    I've been playing with the code you posted, pretty much since you did, trying to figure out how it works. I have some idea of how it works now but, I cannot figure out why I get the set of results, not once but TWICE.
    When I run the query you posted above, this is what I get:
    SQL> @getxml2
    TABLE_NAME                          count
    CLOB_EXAMPLE                            1
    D42                                     1
    DEPT                                    4
    DEPT_2                                  0
    DEPT_ACCIDENTS                          6
    DEPT_EAST                               2
    ... some tables deleted to shorten the output
    T1                                      1
    T10                                    10
    T100                                    0
    22 rows selected.
    TABLE_NAME                          count
    CLOB_EXAMPLE                            1
    D42                                     1
    DEPT                                    4
    DEPT_2                                  0
    DEPT_ACCIDENTS                          6
    DEPT_EAST                               2
    ... some tables deleted to shorten the output
    T1                                      1
    T10                                    10
    T100                                    0
    22 rows selected.
    SQL>The result is shown TWICE. I cannot figure out why. Any ideas as to why the result is shown twice ? (I ran the statement from SQL*Plus and started a fresh instance of SQL*Plus to ensure that no settings from previous scripts would be the cause).
    Thank you for your help, great little piece of code!
    John.
    Edited by: 440bx on Jul 16, 2010 5:30 PM
    Edited by: 440bx on Jul 16, 2010 5:31 PM - corrected name in Hello greeting
    Edited by: 440bx - 11gR2 on Jul 17, 2010 2:55 AM - corrected misspelling
    Edited by: 440bx - 11gR2 on Jul 17, 2010 2:56 AM - corrected another misspelling

  • How do you execute macros in excel using forms--urgent

    i want to execute a macro which is in excel from forms. i am using the dde built in. how ever when given the command
    dde.execute ( conv_id,'[module1.macro1()]', 1000 );
    i get an oracle error. and the macro does not get executed.
    how ever when the same was tried for word it worked.
    can any one help me in this regards
    thanks in advance
    sethuraman.r

    A db procedure as an autonomous transaction may be
    sufficient for your needs.No. An autonomous transaction will run in its own transaction, but never in an asynchronous way.
    Francois

  • How to Edit Post Script file Programitically Using PSUTILS in Windows XP

    I am haiving millions of post scripts file. Each having 4 to 5 pages. Except at page number one each page has little content. So though the content size is small but stationery wastage is quite high.
    I googled arround and came to know about a produch PSUTILS that could narrow down my page numbers.
    But unfortunelely, I am not able to get through that how it works.
    Anybody having idea may please expalin in detail step by step that how to use Psutils. Anyother like software may also be intimated please.
    PSUTLIS may be downloded from
    http://gnuwin32.sourceforge.net/packages/psutils.htm
    My sample PS file can be downloaded from
    https://www.dropbox.com/s/m80x4hfcpf49r5x/1010493909.ps
    Regards
    [email protected]

    Hi gimbal2,
    about code
    jTextArea1.setText(e1.getMessage());I am using this code so that the user will be prompted with a message rather than stack trace.
    About the issue I am getting on linux i believe its because of following statement.
    processBuilder = new ProcessBuilder("sqlplus",userName+"/"+password+"@"+databaseName, script_location); //ORACLERegards,
    Ajay
    Edited by: Ajay Sharma on Nov 23, 2012 12:05 PM
    Edited by: Ajay Sharma on Nov 23, 2012 12:06 PM

  • How Can I execute a java program using java code?

    {color:#000000}Hello,
    i am in great trouble someone please help me. i want to execute java program through java code i have compiled the java class using Compiler API now i want to execute this Class file through java code please help me, thanks in advance
    {color}

    Thanks Manko.
    i think my question was not clear enough.. actually i want to run this class using some java code . like any IDE would do i am making a text editor for java, as my term project i have been able to complie the code usign compiler api and it genertaes the class file but now i want to run this class file "THROUGH JAVA CODE" instead of using Java command. I want to achive it programatically. do you have any idea about it.. thanks in advance

  • How do you call scripts in subfolders using ODT 11.1.0.5.10 beta?

    Hello,
    I'm trying to create a script that calls several other scripts. The scripts I want to call are in a subfolder. Does anyone know the syntax I can use to call them?
    Structure:
    Providers
    +---Create All Script.sql
    +---Create
    +-------InstallOracleASPNETCommon.sql
    +-------InstallOracleMembership.sql
    +-------InstallOraclePersonalization.sql
    In Create All Script.sql, I added the following code and ran it using the "Run" option in my Oracle Database Project:
    @@Create/InstallOracleASPNETCommon.sql;
    @@Create/InstallOracleMembership.sql;
    @@Create/InstallOraclePersonalization.sql;
    The error I get is:
    Connected.
    SP2-0103: Nothing in SQL buffer to run.
    SP2-0310: unable to open file "Create/InstallOracleMembership.sql"
    SP2-0103: Nothing in SQL buffer to run.
    SP2-0310: unable to open file "Create/InstallOraclePersonalization.sql"
    Any help is appreciated. Thanks!

    Okay, I should probably clarify that I'm trying to call scripts using a relative path rather than the full path.
    I know I can use: @D:\Documents\CAL.MB\Oracle.New\Scripts\Create\MyTable\Create.sql;
    But I really want to use:
    @Create\MyTable\Create.sql
    Does anyone know the syntax for this or if it can be done when using the Run, Run on, or Run SQL Plus options?

  • How to properly cite images and media used as to copyright

    All of the images and media used in my iBook were either created by me or gotten from an Open Educational Resource repository such as Wikimedia Commons and are CC licensed such that I am permitted to use them.  Wanting to avoid any delay in getting onto the iBookstore or have any questions raised about these assets after publication, I would like to cite these facts somewhere in my iBook.  I'd rather not use captions for this since the citations will include long, ugly URLs.  Traditional books have a page listing illustrations but I see no equivalent in the templates available by default. 
    So what is the best way to include information like this?  Should I include a list of illustrations and media in a Reference section?

    There are lots of different ways to cite the source of the image. I guess a big question is do you want to credit the source (or perhaps you are required by the license) right beside the image or is it okay to credit the picture at the back in a reference section.
    Personally, I like to credit the source by the picture and put something like "Photo by John Smith / genericStockAgency" in the caption. Alternatively you can credit the source in a section at the back (e.g., see E.O Wilson's life on earth).
    I'd suggest looking at various other ibooks and find a style that you like. BTW most books I have seen do not provide deep linking URLs for individual images and just list the source generically. E.g., image from wikimedia commons.

  • How to Properly Execute tmux When bash is Invoked

    When I invoke urxvt, tmux works as intended, but ps displays the following process tree:
    urxvt
    \_ tmux
    \_ [tmux] <defunct>
    tmux
    \_ -bash
    \_ ps auxf
    I have the following in ~/.bashrc:
    [[ -z $TMUX ]] && tmux && exit
    Any ideas why this tmux zombie exists?
    Last edited by rnabioullin (2011-10-06 00:02:59)

    Because zombies are hard to kill
    Edit: sorry, the potential for more serious answers is still high.
    Last edited by the sad clown (2011-10-05 02:30:21)

  • How can I execute program after using F4_Filename function?

    Hi all,
    I'm a new user on the forum. I've been working with ABAP and SAP for a few weeks. I wrote a program for importing data from excel file to SAP using BDC. During searching this forum I found information about F4_Filename function which allows users to browse the disc for a file. I'd like to add this function to my program. I have a parameter for a file name but this is an ordinary static string field. When I added the code which I found in the message on this forum the rest of program doesn't execute.
    This is simple program for example:
    REPORT  Z_TEST8_AB.
    DATA f_name TYPE STRING.
    PARAMETERS p_file like rlgrap-filename DEFAULT 'c:\test.xls'.
    f_name = p_file.
    write:/ f_name.
    This program works correctly. There is a field for parameter. I can change the default name for a file.
    After all, I can run the program (F8) and rest of the code is executed. The field for parameter dissapears from the screen and the file name is displayed. ( command write)
    Now I added a function F4_Filename
    REPORT  Z_TEST8_AB.
    DATA f_name TYPE STRING.
    PARAMETERS p_file like rlgrap-filename DEFAULT 'c:\test.xls'.
    at selection-screen on value-request for p_file.
      call function 'F4_FILENAME'
           exporting
                program_name  = syst-repid
                dynpro_number = syst-dynnr
                field_name    = 'p_file'
           importing
                file_name     = p_file.
    f_name = p_file.
    write:/ f_name.
    I can browse a computer for a file now but after selecting the file I can't run the rest of the code. When I click on the icon or press key F8 the field for parameter doesn't dissapier and the command write is not executed.
    What do I do wrong?
    Could anyone suggest me a solution? How can I executed the code after using this function?
    Thanks in advance.
    Regards,
    Arek.

    Hi arkadiusz,
    1. simple
    2.
    <b>start-of-selection.</b>
    f_name = p_file.
    write:/ f_name.
    regards,
    amit m.

  • How to run a script from Calculation Manager

    Hi All,
    I would like to know how to run a script made by using Calculation Manager. I have converted a simple rule script which has just one statement(HS.EXP "A#Sales = 100") in "Sub Calculate()" by using FMRulesMigrator.exe and then imported, deployed to an application. when I execute "Calculate" from a Data Grid, the rule didn't take effect to application data. If I load the script by using classic rule editor, it works fine.
    Is there anything I have to know to run a rule script which is made by using Calculation Manager?
    Thanks in advance.
    CY.

    Hi,
    Refer the following the link for calling logic from new custom buttons using VBA.
    https://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/f085dd92-a40c-2c10-dcb1-a7c24476b23a
    hpe this ll help.
    thnks.

  • How to send XML file into XI using sender HTTP adapter

    I am using HTTP sender adapter to post the XML file into XI. I tried to form the URL by using the following String query , but I am unable to execute file.
    String urlString = "http://<servername:portno>/sap/xi/adapter_plain?namespace=<namespace>&interface=<interface name>&service=<service name>&party=&agency=&scheme=&QOS=BE&sap-user=xiappluser&sap-password=satyam&sap-client=100&sap-language=EN";
    How can I execute xml file by using HTTP sender adapter.
    Any one with better suggestions, about this idea?
    Thanks in advance for all.
    Ram Raj

    Hi
    Just use the following parameter to send xml file using HTTP adapter.
    "http://xiserver:8000/sap/xi/adapter_plain?namespace="senderNamespace"&interface=senderinterface&service=sender service";
    "&party=sender party"&agency=&scheme=&QOS=BE&sap-user=userid &sap-password=password&sap-client=100&sap-language=D";
    with the help of this you are able to point out which interface you would like to use.
    And in payload pass the xml.
    and thats it
    carry on
    Cheers
    Regards
    Piyush

  • Executing sequence of commands using exec

    How do I execute sequence of commads using java.lang.Runtime.exec()?
    As a part of an assignment, I need to use the exec command to
    a. change drive and then
    b. change directory and then
    c. execute some command.
    Thanks.

    windows
    "pushd <dir path> && <some command>"

Maybe you are looking for

  • Vi control of Thorlabs TDC001 motor control,need to generate a ref # for ActiveX

    I am trying to create a custom program for control of a Thorlabs TDC001 motor controller.   The stand alone Thorlabs software works,  I also created a Active X window using the Thorlabs software in Labview.  I would like to create an automated look w

  • Reg: indexes

    Hi,   I created one table which having primary index fields "3".  I m using this table in the reports as shown below select * from ztab where A2 = field1. (A2 is second field of index fields).   I used only one field from the index fields. Is the abo

  • NEXUS 2232TM and Nexus 5010P

    HI ALL, does Nexus 2232TM can work as a FEX for N5010P? if so can we also use FET to connect the above two switches? Thanks Ahmed

  • I can't buy OmniFocus in MAC APP STORE

    APP STORE E rror, Plase try angin later,(100) How could I buy this app? I can buy app in iTunes, but can't do the same thing in MAC app store? Why?

  • SQL*Loader-266: Unable to locate character set handle for None

    Hi All, I am getting "SQL*Loader-266: Unable to locate character set handle for None" through sql loader. NLS Parameters are : NLS_LANGUAGE AMERICAN NLS_TERRITORY AMERICA NLS_CURRENCY $ NLS_ISO_CURRENCY AMERICA NLS_NUMERIC_CHARACTERS ., NLS_CALENDAR