Thursday, December 24, 2015

What is multitenancy - logically isolated- physically maynot be

Multitenancy

Multitenancy is a reference to the mode of operation of software where multiple independent instances of one or multiple applications operate in a shared environment.

The instances (tenants) are logically isolated, but physically integrated.

The degree of logical isolation must be complete, but the degree of physical integration will vary.

The more physical integration, the harder it is to preserve the logical isolation.

The tenants (application instances) can be representations of organizations that obtained access to the multitenant application (this is the scenario of an ISV offering services of an application to multiple customer organizations).

The tenants may also be multiple applications competing for shared underlying resources (this is the scenario of a private or public cloud where multiple applications are offered in a common cloud environment).



from: http://www.gartner.com/it-glossary/multitenancy
ISV - independent software vendor

get remote host volumes in gluster



How do you get remote node's gluster volume(s):

gluster volume info --remote-host=gfvm4

yes , --remote-host= plays the key part here ;)


Monday, December 14, 2015

SIGTERM vs SIGKILL and some more

SIGTERM vs SIGKILL 

kill will send SIGTERM signal
- may stop OR not.
- may be ignored.

kill -9 will send SIGKILL signal
- carries little more weight than SIGTERM
- 9 indicates SIGKILL-  CANNOT be ignored by process
-  SIGKILL directly goes to the init process.
   - init will stop the process.

Processes into "uninterriptible sleep"(D state) cannot be killed by kernel either. Reboot is required.

SIGKILL: Terminates a process immediately. This signal cannot be handled (caught), ignored or blocked. (The "kill -9" command in linux generates the same signal).


SIGTERM: Terminates a process immediately. However, this signal can be handled, ignored or caught in code. If the signal is not caught by a process, the process is killed. Also, this is used for graceful termination of a process. (The "kill" command in linux if specified without any signal number like -9, will send SIGTERM)

SIGINT: Interrupts a process. (The default action is to terminate gracefully). This too, like, SIGTERM can be handled, ignored or caught. The difference between SIGINT and SIGTERM is that the former can be sent from a terminal as input characters. This is the signal generated when a user presses Ctrl+C. (Sidenote: Ctrl+C denotes EOT(End of Transmission) for (say) a network stream)

SIGQUIT: Terminates a process. This is different from both SIGKILL and SIGTERM in the sense that it generates a core dump of the process and also cleans up resources held up by a process. Like SIGINT, this can also be sent from the terminal as input characters. It can be handled, ignored or caught in code. This is the signal generated when a user presses Ctrl+\.

SIGSTP: Suspends a process. This too, can be handled, ignored or blocked. Since it does not terminate the process, the process can be resumed by sending a SIGCONT signal. This signal can be generated by pressing Ctrl+Z. (Sidenote: Ctrl+Z stands for substitute character which indicates End-of-File in DOS)

SIGHUP: (From Wikipedia): Hangs up a process when the controlling terminal is disconnected. This especially relates to modem/dial in connections. A process has to explicitly handle this signal for it to work. A good use is to "poke" a process and letting the process (as defined by the programmer) decide what to do with the signal is described here. Hence, SIGHUP can be handled,ignored or caught. This is the signal generated when a user presses Ctrl+D.


Link: http://programmergamer.blogspot.in/2013/05/clarification-on-sigint-sigterm-sigkill.html

symbolic link affecting program behaviour


symbolic links affect program behaviour ? how?

In a C program, the command line is stored in argv, which is short for argument vector.

The progam's name is the first element of argv, i.e. argv[0].

Clearly in the case of halt and reboot, the program is changing its behavior based on argv[0].

# reboot

ps -p -o cmd or cat /proc/cmdline.

so in program depending upon argv[0] behaviour changes !


Ref: http://unix.stackexchange.com/questions/6787/why-do-some-symbolic-links-affect-program-behavior





deleting a forked repo from github


 deleting a forked repo from github :

http://stackoverflow.com/questions/11302639/delete-forked-repo-from-github

By far the easiest way is to log in gitHub account:
  1. Click to your repository {for example yourUsername/yourRepository for example igort/vuk}
  2. Then in the main toolbar of github click on Settings
  3. Scroll just a little bit down and you will find Delete this repository button
  4. When you click it another pop up will appear here you need to type in the name of your repository and click on the button below which says: I understand the consequences, delete the repository