ZTIMES Office |
#Renew, #New, #Main Menu #Admin Utility #Zipcodes sort db Note: How To Mail Merge print PDF postcards and letters | |
lastname,firstname,company fields are ALL CAPS; search anything is CASE SENSITIVE; Use search anything ALL CAPS for a company; otherwise for address, use case sensitive input. |
Admin Advertiser CC charges cp /home/web/cgi/accounting/accounting.cgi /usr/lib/cgi-bin/accounting |
ZTIMES web => /home/web #Subscribe data =>
/home/subscribe #CGI programs => /usr/lib/cgi-bin #Baks => NAS and
GWSERVER #Phone Numbers #other stuff
#WF IP 98.109.125.21 #GW IP 71.172.81.62 WF Post Off 908 301-0950 (Dan); 233-1168 Lobby; SP Post Off 908 322-4747 Pete Billson Pete@elbnet.com cell 908-447-9961 office 317-8606; TH-R ftp.recordonline.com, Username: Westfield-Leader - Passwd: we$tf!eld #WF Fire Dept 908 789-4130 |
rsync FIND | ssh horace@71.172.81.62 | ssh horace@zserver | ssh horace@ztimes | Ref: Debian - Perl - HtDig | Subscribe Upgrade Plan | zubscribe |
BACKUP machines WF: NAS; ZSERVER; ZTIMES; LEADER; Garwood: GWSERVER (IP 71.172.81.62 gateway 71.172.81.1; dns1 71.250.0.12 dns2
71.242.0.12) |
Backup Details => |
GW crontab 10 22 * * 0 root /home/zaplist.cgi =>
prunes on Sunday excess rsync dirs; keeps 2 previous changes. Gen'l. crontab e Mail: (horace rsync -v) default mails to horace. Changed ZSERVER default by adding to top of its crontab MAILTO=zeus@goleader.com For no email, use MAILTO="". Perl scripts called by crontab can send mail anywhere. |
Backup Chart |
2014-05-10 |
GW=GWSERVER |
GW 71.172.81.62 |
|||
Function Description |
Function Location |
Backup Location |
Backup Type |
Method |
Comment |
Status |
Newspaper Production |
Zserver/home/newspaper |
ZTIMES/baknews |
rsync/30 m; |
crontab Ztimes |
24/7 rsync pull by ztimes |
Operational |
TIW Production | Zserver/home/TIW | ZTIMES/bakTIW | rsync daily | crontab Ztimes | daily rsync pull by ztimes | |
|
purge baknews weekly | ZTIMES/baknews | cron Thurs; rm -rf *30; *00 | crontab Ztimes | purge folder weekly |
To Be Done |
Zserver/home/newspaper |
NAS/zserver/newspaper |
rm * nightly |
crontab Zserver |
purge Nas/.../folder |
Operational |
|
Zserver/home/newspaper | NAS/zserver/newspaper | cp * nightly | crontab Zserver | cp to NAS/.../folder |
Operational |
|
Newspaper Archives |
NAS/newspaper |
GW/... via ZTIMES/... |
cp & rsync pdfs reqd |
crontab Ztimes getpdf.cgi |
get NAS pdfs & rsync to GW |
Operational |
Business |
Zserver/home/business |
NAS/zserver/business |
cp * nightly, overwrite |
crontab Zserver |
Operational |
|
Zserver/home/business |
GW/home/bak_business |
rsync nightly |
crontab Zserver |
Operational |
||
Sales |
Zserver/home/sales |
NAS/zserver/sales |
cp * nightly, overwrite |
crontab Zserver |
Operational |
|
Zserver/home/sales |
GW/home/bak_sales |
rsync nightly |
crontab Zserver |
Operational |
||
Community |
Zserver/home/community |
NAS/zserver/community |
cp * nightly, overwrite |
crontab Zserver |
Operational |
|
Zserver/home/community |
GW/home/bak_community |
rsync nightly |
crontab Zserver |
Operational |
||
TIW | Zserver/... | NAS/zserver... | cp * nightly, overwrite | crontab Zserver |
Operational |
|
arc_distill | Zserver/... | NAS/zserver... | rm *, weekly | crontab Zserver | purge Nas/.../folder |
Offline |
Zserver/... | NAS/zserver... | cp *, weekly | crontab Zserver | cp to NAS/.../folder |
Operational |
|
Subscribe data |
Ztimes/home/subscribe |
NAS/ztimes/subscribe |
cp PIT nightly |
crontab Ztimes baknas.cgi |
GUI=web; code=cgi-bin |
Operational |
Ztimes/home/subscribe |
GW/home/bak_subscribe |
rsync nightly |
crontab Ztimes |
Operational |
||
CGI scripts |
Ztimes .../cgi |
NAS/ztimes/cgi-bin |
cp * nightly, overwrite |
crontab Ztimes baknas.cgi |
Operational |
|
Ztimes .../cgi |
GW/home/bak_ztimes/cgi-bin |
rsync nightly |
crontab Ztimes |
Operational |
||
Backup scripts |
Ztimes/backup |
NAS/ztimes/backup |
cp * nightly, overwrite |
crontab Ztimes baknas.cgi |
Operational |
|
Ztimes/backup |
GW/home/bak_ztimes/backup |
rsync nightly |
crontab Ztimes |
Operational |
||
Ztimes Web |
Ztimes/home/web |
NAS/ztimes/web |
cp * nightly, overwrite |
crontab Ztimes baknas.cgi |
Operational |
|
Ztimes/home/web |
GW/home/bak_ztimes/web |
rsync nightly |
crontab Ztimes |
Operational | ||
SuperSearch | Ztimes/data/Supersearch | NAS/ztimes/SuperSearch | smart cp | crontab Ztimes baknas.cgi | Perl determines what's needed |
Operational |
SSH GWSERVER
Notes: ZTIMES scp and rsync Westfield files to GWSERVER
including newspaper, business, subscriber and programs for safeguard.
Garwood has 4 WINxp workstations in storage ready to be networked there to yield a functioning
office. GWSERVER files can be used to restore Westfield. horace@ZTIMES
or horace@ZSERVER connect to horace@GWSERVER using SSH (port 22); rsync provides secure transfer over the Internet
[some Perl scripts]. Security: only usr horace
with keys is permitted. Password login is disabled. To manually connect, log on
horace@ZTIMES then CMD$: ssh horace@71.172.81.62
or perl /backup/getpdf.cgi -
SSH Keys respectively permit only horace@ZTIMES
or horace@ZSERVER to connect to horace@GWSERVER. GW is fixed IP. Routers: WF is Verizon [192.168.0.20 admin,cbcc09] GW is Verizon [192.168.1.1 admin HrCwlT05 or HrCwlT??, I forget] GW router has port 22 forwarded to horace@GWSERVER. xxx obviated 2014-01-26 GW has dynamic IPP so every 5 minutes using ddclient, it tells noip.com what its IPP is. GWSERVER address thus is via horace@garwoodhouse.no-ip.org [our account at noip.com, business@goleader.com, HrCwlT05]. Removed WF router Cisco rv042 (adminoffice HrCwlT11) and removed GW router Cisco wrv210 192.168.2.22:80 admin HrCwlT13 |
Samba shares, users |
ZSERVER shares folders to Windows workstations via Samba. See
/etc/samba/smb.conf - cmd $ testparm - Samba users must be added to the
server. smbpasswd -a userxyz - when prompted for password: cbcc [default] - Restart Samba: /etc/init.d/samba restart |
Linux Users |
To see linux users, read file etc/passwd.
To prevent mess: add most users with No Login: useradd -s /usr/sbin/nologin
username To Add users normal: useradd userxyz To see groups, read file etc/group. To add group: groupadd group5; to add users to a group, edit the file, i.e.: group5:x:1023:legals,atlas,zeus,horace |
Linux Command Prompt |
simple: chmod 666 filename chmod
755 dirname chown atlas:group1 filename [or dirname,
group is optional] dir chmod recursive: root@zserver: /home/newspaper: find . -type d -exec chmod 775 {} \; changes mod, all directories only below /home/newspaper dir chown recursive: root@zserver: /home/newspaper: find . -type d -exec chown atlas:group1 {} \; changes owner, all directories only below /home/newspaper files chmod recursive: root@zserver: /home/newspaper: find . -type f -exec chmod 666 {} \; changes mod, all files only below /home/newspaper files chown recursive: root@zserver: /home/newspaper: find . -type f -exec chown atlas:group1 {} \; changes owner, all files only below /home/newspaper -- To edit a file, Use: nano filename; do the edits; ^o write to memory; save filename (enter); ^x to exit -- tree -A -L 2 -- Disk info: du --help du -h du -sh du -a du -k du -ch df -T -- Disk free: df --help df -h ...etc -- EMAIL, type: mutt -- add bash path for home dir: export PATH=$PATH:~/bin -- scp path/filename horace@71.172.81.62:/home/horace/filename -- for HD info as root lshw -class disk -class storage -- lshw -short -C disk -- udisks --dump | less -- tar Contents, first see what's in it: tar tf filename -- tar Extract, copy it somewhere safe, to extract it: tar xf filename |
SSH Keys |
Add
Public SSH Key to Server in a Single Command
- OK for our LAN servers (GWSERVER security blocks this.
password login=no) # If you want to setup SSH keys to allow logging in without a password, you can do so with a single command. such as from horace@ztimes => horace@zserver # Only if necessary run the keygen command to generate the keys: ssh-keygen -t rsa => see if files exists /home/horace/.ssh/ id_rsa id_rsa.pub known_hosts # to make pub key only (-y option) because id_rsa already exists: ssh-keygen -t rsa -y > ~/.ssh/id_rsa.pub # Then use this command to push the key to the other server, modifying it to match your server name. cat ~/.ssh/id_rsa.pub | ssh horace@otherserver 'cat >> .ssh/authorized_keys' Get IP using terminal: wget -qO- http://ipecho.net/plain ; echo or to file wget -qO- http://ipecho.net/plain > ip.txt |
RSYNC How To |
# Example: Pull from ztimes to zserver (SSH keys are setup, no password
req'd) Permissions: 775 horace root baknews # logon horace@zserver, then issue CMD: rsync --backup --backup-dir=`date +%Y.%m.%d.%H.%M` -aO horace@ztimes:/data/_newspaper /baknews/ Using zserver crontab (escape % => \%) */30 9-19 * * 0-6 horace rsync --backup --backup-dir=`date +\%Y.\%m.\%d.\%H.\%M` -aO horace@ztimes:/data/_newspaper /baknews/ This yields the folders recursive as is plus PIT past files before changes were made; enables recovering past files, i.e. if they were corrupted or something |
Upload to goleader |
Use this secure procedure to upload files such as Advertisements and Photographs direct to our
goleader server. This enables multiple uploads and there is no file size limit. Items are immediately delivered to our system. This overcomes file size limitation and uncertainty of email. We receive notice of all uploads and give this top priority. If you have questions, call (908) 232-4407 or email: editor@goleader.com Go to www.goleader.com/upload username: leader password: HRCWLT05 Follow prompts. Wait until upload completes. Repeat as needed. Advertisers: Please upload your Ad and order details. Also, email details to sales@goleader.com; Confirmation will be provided. Price and details are at www.goleader.com/presskit Photographs: Include a file with caption information. Photo adjustment is not necessary, as we adjust all photos. Major photography events are posted on the Net. See examples at www.goleader.com/photos If you have multiple files to upload, zip them into one file and upload the zipped file. This saves you from having to upload each file and staying by your computer. |
General Info |
Pete Billson Pete@elbnet.com cell 908-447-9961 office 908-317-8606;
Mail at Elbnet -
goleader,HrCwlT12; phone technician Ed Walters (Arrow) cell 908 447-3494;
Lauren Barr IPP 76.117.109.61 Stringer manual and Stringer Invoices; HTDIG: http://www.scrounge.org/linux/htdig.html - our webmail https://webmail.verizon.net/signin/ Skype horace.corbin dragonssigmapi1 |
Obit to invoice payment from office; enter the word 'invoice' in the company box and submit |
Maintain:
Posting News to www.goleader.com -
For users in the office, this program (maintain.cgi) manipulates the file for the week and
www.goleader.com/news/posting.htm 1. Go to the current week of goleader 2. At the end of the browser address, type "maintain.cgi" and press enter; then click Proceed; if to see Help, click continue 3. If to Add an entry, paste the entry in the box of the form; type add in the command box; press enter. Certain privileges are also given to do this for authorized people outside the office (Lauren Pass IPP 76.117.109.61) She maintains our twitter and facebook too. Also enabled is gwserver. To see Help for other stuff, don't type in the command box; press enter. |
Guide to Unix/Commands/Utilities - Data Universe - Make goleader Video - HRC eBook in Progress, see //atlas:c:/reference |
goleader.com Updating index.cgi is edited to redirect visitors to the specified week. Beforehand, see below. The Folder for the week with template.htm edited to the content as desired is uploaded. Each folder also contains maintain.cgi Go to the week desired with browser and add maintain.cgi, then enter. i.e. www.goleader.com/14mar06/maintain.cgi maintain.cgi updates index.htm using template.htm; also it manages posts; Read instructions by clicking Proceed button, then clicking Continue button. It also manages news additions => www.goleader.com/news/ #Weekly folder... Create photos and template. htm => Example \\ZTIMES\data\2014_goleader Make photos required and save to the folder. Edit template.htm as necessary to for the page (captions, headlines, links pdf to pages, etc.). Fonts are controlled by the style sheet => http://www.goleader.com/goleader.css #... Upload folder to the online target directory (i.e. 09sep24) and set file permissions. Make the pdf pages. Upload all applicable files to the target directory online. Set file permissions to 666 for index.htm and index.tmp (to enable them to be dynamically updated). #... Check/correct work online for template.htm - Go online to the [target directory]/template.htm Check all links, spelling; photos, captions, look & feel, etc. #...Activate, see instructions for maintain.cgi Check index.htm to be sure all is correct. #...Bring online, make [target directory] to be the current directory online. edit index.cgi to redirect the site to the [target directory]; Example, edit line of index.cgi to be: print "Location: http://www.goleader.com/09sep24\n\n"; upload edited index.cgi to overwrite existing index.cgi - Note: file permissions of cgi files must be 755 #... Check www.goleader.com that it now gets redirected to the specified folder. |
MAIL Setup:
LEADER.goleader.com is the LAN
MailServer for the local workstations. It uses Exim4. LEADER
fetchmail grabs the Internet mail from www.goleader.com and distributes
it to the workstations. www.goleader.com also mirrors the mail to
Verizon and AOL webmail accounts such that it can be read from the
Internet; and as backup. ZTIMES and ZSERVER use Exim4 Mail in "satellite mode" for system communication between machines on the LAN. Configuring Exim on a Debian machine, is to make it a ‘satellite’; which uses another SMTP server (LEADER.goleader.com) for sending and does not do local delivery. It is used by other computers in the network to send mail, but also by the machine itself, to send system notifications. These machines are manually configured. Use gedit, not Windows text editor because of line end differences. The following files are edited: /etc/mailname; /etc/aliases; /etc/exim4/update-exim4.conf.conf for ztimes and zserver # /etc/mailname goleader.com |
for ztimes and zserver
# /etc/exim4/update-exim4.conf.conf dc_eximconfig_configtype='satellite' dc_other_hostnames='goleader.com' dc_local_interfaces='127.0.0.1' dc_readhost='goleader.com' dc_relay_domains='' dc_minimaldns='false' dc_relay_nets='' dc_smarthost='leader.goleader.com' CFILEMODE='644' dc_use_split_config='false' dc_hide_mailname='true' dc_mailname_in_oh='true' dc_localdelivery='mail_spool' |
for ztimes and zserver
# /etc/aliases mailer-daemon: postmaster postmaster: root nobody: root hostmaster: root usenet: root news: root webmaster: root www: root ftp: root abuse: root noc: root security: root root: horace |
for ztimes and zserver after configuring Exim # /etc/init.d/exim4 restart - This automatically regenerates config.autogenerated from exim4.conf.template. |
![]() |