Posty

Wyświetlanie postów z styczeń, 2019

AWS Egzam

1. AWS SysOps Administrator Associate Exam -150 $  - 130 Minutes (2 minutes per question) - 65 Questions - You can afford to get 18 question wrong - ~72% Passing Score - Valid 3 years - exam code is SOA-C01 - Qusetions     * 22 % Monitoring and Reporting  - 14.3 (14-15) Questions     * 8 % High Availability  - 5.2 (5-6) Questions     * 14 % Deployment and Provisioning  - 9.1 (9-10) Questions     * 12 % Storage and Data Management  - 7.8 (7-8) Questions     * 18 % Security Compliance  - 11.7 (11-12) Questions     * 14 % Networking  - 9.1 (9-10) Questions     * 12 % Automation and Optimization  - 7.8 (7-8) Questions - Content: Domain 1: Monitoring and Reporting 1.1 Create and maintain metrics and alarms utilizing AWS monitoring services 1.2 Recognize and differentiate performance and availability metrics 1.3 Perform the steps necessary to remediate based on performance and availab...

Szeregowanie zadań

1. Szeregowania zadań w systemie przemysłowym -W procesie produkcyjnym typu przepływowego wytworzenie każdego wyrobu wymaga wykonania sekwencji operacji na specjalistycznych (dedykowanych) maszynach uporządkowanych w ciąg zgodny z realizowanym procesem. Dla problemu przepływowego ograniczenia kolejnościowe dla każdego wyrobu tworzą graf w postaci łańcucha operacji, w którym kolejność wykonywania operacji jest zgodna z kolejnością ustawienia maszyn na linii produkcyjnej. Na ogół zakłada się, że liczba operacji koniecznych do wykonania każdego wyrobu jest równa liczbie maszyn w linii. W ten sposób każdy wyrób charakteryzuje ciąg [t ij ,...,t mj ] czasów wykonywania operacji na kolejnych maszynach. Wówczas mamy do czynienia z idealnym systemem przepływowym -algorytm jonsona daje rozwiązania optymalne ale dla dziur nie jest optymalne a) idealny system przepływowy Kierunek przepływu wszystkich zleceń przez maszyny jest ten sam. Dla idealnego systemu przepływowego liczba zadań j...

netsh command

netsh wlan set hostednetwork mode=allow ssid=NAZWA key=HASŁO netsh wlan start hostednetwork

Python script for pdb databases

import os import sys import urllib2 import string #url = 'http://www.rcsb.org/pdb/rest/search' chain = sys.argv[2] id = sys.argv[1] d1 = id+"."+chain url1 = 'http://www.pdb.org/pdb/rest/describeMol?structureId=' url = url1+d1 req = urllib2.Request(url) f = urllib2.urlopen(req) result = f.read() #print "Found number of PDB entries:", result.count('\n') wynik = [] wynik = result b= string.split(wynik,'\n') for i in range (len(b)): if '<polymerDescription description' in b[i]: wynik = b[i] a=[] c= string.join(wynik,'') for i in range (len(c)): #print c[i] if '"' is c[i]: a.append(i) end=[] for i in range (len(c)): if i<a[1] and i>a[0]: end.append(c[i]) print string.join(end,'')

AWS Architectures

https://docs.aws.amazon.com/vpc/latest/userguide/VPC_Scenario2.html

Terraformize AWS infrastructure

https://nickcharlton.net/posts/terraform-aws-vpc.html https://docs.aws.amazon.com/vpc/latest/userguide/VPC_Scenario2.html https://github.com/netguru/DataAnnotation-infrastructure/tree/aws-staging-terraform/aws-terraform https://www.hiveit.co.uk/labs/terraform-aws-vpc-example/terraform-aws-vpc-tutorial-4-create-the-application-load-balancer

bash script

Obraz
1) shell scripting 2) how to create and use variables 3) Testing and decision making 4) command line argument processing 5) input and output, include user input 6) if statements 7) exit statuses 8) functions 9) 10) 11) 12) 13) #!/bin/bash #comment echo "Hello World!" myName="name" #variable #all variable are trited as a string # no space on either side of = #declar a constant declare -r NUM1=5 num2=4 num3=$((NUM1+num2)) num3=$((NUM1-num2)) num3=$((NUM1*num2)) num3=$((NUM1/num2)) echo "5 + 4 = $num3" echo $((5**2)) echo $(( 5%4 )) i += 2 i + i =2 rand=5 let rand+=4 echo "$rand" echo"rand++ = $((  rand ++ ))" echo"++rand = $(( ++ rand ))" echo"rand-- = $((  rand -- ))" echo"--rand = $((  --rand ))" num7=1.2 num8=3.4 num9=$(pythin - c "print $num7+$num8") echo $num9 cat<< END This text prints on many lines END #Func...

Linux

1) Linux useful commands #redo last command but as root sudo !! #open an editor to run a command crtlx+e #create . a super fast ram disk mkdir -p /mnt/ram mount -t tmpfs tmpfs /mnt/ram -o size=8192M #don't add comand to history (note the laeading space  ls -l . #fix a really long command that you messed up fc #tunnel with ssh (local port 3337 -> remote host's 127.0.0.1 on port 6379 ssh-L 3337:127.0.0.1:6379 root@emkc.org -N? #quickly create folders mkdir -p folder/{sub1, sub2}/{sub1, sub2, sub3} #intercept stdout and log to file cat file | tee -a log | cat > /dev/null #exit terminal but leave all processes running disown -a && exit 2) Linux boot process a) BIOS - Basic Input/Output System - Special firmware - It's operating system independent   * this is not unique to the Linux OS - Primary purpose is to find and execute the boot loader -Performs the POST   * Power-On Self Test -Knows about bootable devices: ...

vim

esc:i   - insert mode esc:q! -   quit and discard changes esc:wq -   save and quit esc:w -   save but not exit esc: set number - display numbers of line esc: syntax on - syntax higlithing on esc: set tabstop=2  how many spaces with the tab esc: set autoindent - autoindent in vim editor w - front of next word b - backwords front of next word 0 - start of the line $ - end of the line G- end of the last line I-end of the last line and allow you to typeing (insert mode) configure your editor in ~/.vimrc sample: set number syntax on set autoindent echo $MYVIMRC . // env var which points vim configuration file V↓d -select everthing and delete