MariaDb Galera Cluster error with libgalera_smm.so config - database-replication

I am trying to setup a Galera cluster between three MariaDb nodes. However, i cannot even pass through the config of the first node. When i do the config and try to restart MariaDB, it seems to be having a problem with lines starting with wsrep_ in the config file (/etc/my.cnf.d/server.cnf).
I am running CentOs-6.5 64-Bits, and the MariaDB version is 10.0x.
The following is a complete config in the /etc/my.cnf.d/server/cnf file:
query_cache_size=0
binlog_format=ROW
default_storage_engine=innodb
innodb_autoinc_lock_mode=2
#The lines below are the ones causing the error and will not let MariaDb start
wsrep_provider=/usr/lib64/galera/libgalera_smm.so
wsrep_cluster_address=gcomm://192.168.1.20,192.168.1.30
wsrep_cluster_name='cluster1'
wsrep_node_address='192.168.1.10'
wsrep_node_name='db1'
wsrep_sst_method=rsync
wsrep_sst_auth=root:password
How can i get around this issue?

I don't see any major problem in your config file,but sometimes small things results into such problem.
Under the 'wsrep_cluster_address' give the IPs of all the three nodes and also put the entire thing in ''.After doing so,it should look like
wsrep_cluster_address='gcomm://192.168.1.20,192.168.1.30,192.168.1.xx'
Hope this solves the issue.

This configuration should be under a section named [mariadb] in your server.cnf file.
Did you provide your whole server.cnf file? If yes, please try to add [mariadb] section header before your configuation.

Related

How to add multiple bases in /etc/default/jetty

I am trying to add multiple jetty bases to jetty server. Documentation says it is possible without providing the information on how to do it.
So in /etc/default/jetty file with single jetty base is which works is
JETTY_HOME=/opt/jetty
JETTY_BASE=/opt/jetty/my_base
JETTY_USER=jetty
JETTY_HOST=jetty
JETTY_ARGS=jetty.http.port=8989
JETTY_LOGS=/opt/jetty/logs/
i have tried combinations
JETTY_HOME=/opt/jetty
JETTY_BASE=/opt/jetty/my_base
JETTY_BASE=/var/www/domain1
JETTY_BASE=/var/www/domain2
...
i have also tried ',' comma separated does not work
JETTY_HOME=/opt/jetty
JETTY_BASE=/opt/jetty/my_base, /var/www/domain1, /var/www/domain2
....
Has anyone managed to get this working, can you let know how to achieve this. Thanks
Create more /etc/default/<name> entries.
Say you want 3 bases.
Lets call them tau, upsilon, and phi.
You'll create ...
/etc/default/tau
/etc/default/upsilon
/etc/default/phi
each of which is a standalone instance of Jetty, with their own ${jetty.base} directory and a common ${jetty.home} directory.
The jetty.sh you (likely) copied into place for your service entry also needs the same name.
So, cp jetty.sh /path/to/service.d/tau.sh becomes how /etc/default/tau is used/searched for.
(Note: depending on your chosen shell, a symlink will probably work too)

Unable to configure Dataduct wrapper for AWS Datapipes

I have the config file in place in the Dataduct directory. But the error i get is config file missing. Can someone please suggest, if I am missing on something.
I know, the answer is late for the author, but perhaps someone else need that.
Based on dataduct documentation the config should be placed into one of this places:
1. /etc/dataduct.cfg
2. ~/.dataduct/dataduct.cfg
3. DATADUCT_CONFIG_PATH - environment variable
I place it into the .dataduct folder in user home (second case) and it works perfectly fine for me.

How to undo move files from filezilla

I have one problem about filezilla. I accidentally move one folder to wrong directory, so it shows the errors when I view my website.
How can I solve it? Please help me.
Many thanks in advance for your answer.
You cannot undo, but you should understand why that happened and how to prevent that from happening again in the future.
This happened because Filezilla allows Drag-and-drop move functionality on both folders (directories) and files, very dangerous on production servers.
There is actually a feature-request for 11 years now, please add your vote to the list to get this done: https://trac.filezilla-project.org/ticket/2191
In the mean time, please consider using another software that allows the user to set this behavior as an option:
WinSCP: http://winscp.net/eng/docs/screenshots
WS-FTP Pro: https://trac.filezilla-project.org/attachment/ticket/2191/ws_ftp-professional-options.gif
EDIT: Filezilla team responded (sort of) to the feature request and you can block drag and drop in the xml config file. It's better than nothing.
You cannot undo ftp moves. The only way to rectify the problem is to manually move the folder to it's original location.
I suggest you be more careful from next time.
If you don't know where the folder belongs, download the x-cart script package and check where the directory belongs.
Sorry for late, but I am up to date. I get logs from filezilla of moved files.
Status: Renaming '/var/www/html/brb/abc.js' to '/var/www/html/brb/node_modules/abc.js'
Status: /var/www/html/brb/abc.js -> /var/www/html/brb/node_modules/abc.js
Status: Renaming '/var/www/html/brb/xyz.html' to '/var/www/html/brb/node_modules/xyz.html'
Status: /var/www/html/brb/xyz.html -> /var/www/html/brb/node_modules/xyz.html
I write script in js to build command
let x = ['/var/www/html/brb/abc.js -> /var/www/html/brb/node_modules/abc.js',
'/var/www/html/brb/xyz.html -> /var/www/html/brb/node_modules/xyz.html'];
let cmd = [];
x.forEach(p => {
let path = p.split('->');
cmd.push(`mv ${path[1]} ${path[0]}`);
})
console.log(cmd);
Output:
['mv /var/www/html/brb/node_modules/abc.js /var/www/html/brb/abc.js'
'mv /var/www/html/brb/node_modules/xyz.html /var/www/html/brb/xyz.html']
Use any editor like vscode etc and remove string quotes and execute command in server terminal etc
mv /var/www/html/brb/node_modules/abc.js /var/www/html/brb/abc.js
mv /var/www/html/brb/node_modules/xyz.html /var/www/html/brb/xyz.html
A simple answer is,
Copy the folder into the desired location and then delete from the current location where you moved it mistakenly.
Now, what if you overwrite a file.
I just edited a file in local, then downloaded the file from my server into the local, and my all the local updated data is gone. There seems no solution of this, but there may be one possibility, I may be the lucky enough that this is my case.
If you were working on that local file, so most probably it is opened in your browser. Do not refresh it. Copy the content one by one, and update the file again. You can also open developers tools of both old and new page. Compare them line by line and do the job.
I had the same issue and resolved it manually.
The log panel was helpful in this. It is the large panel below the connection form in the top menu.
From that log panel, I was able to figure out all the files which were moved with their current and previous location.
I copied those all log lines and paste them somewhere in notepad and then manually selected all files and move those all at once to their original directory.
Screenshot: The log panel showing last actions

Using PuPHPet to configure Vagrant, but need more advanced options

I'm currently using the PuPHPet Vagrant config page. Once completed I then have to manually set a few other things up. This isn't ideal, and ideally PuPHPet will do it all in one go.
(1) I don't see the Apache mod_expires available in the options. I want to set this on puphpet.com somehow.
(2) I also currently have to edit this line in my Vagrantfile:
config.vm.synced_folder "#{folder['source']}", "#{folder['target']}", id: "#{folder['id']}", type: nfs
...and add this to the end:
, mount_options: ["dmode=777,fmode=777"]
It prevents Vagrant complaining of file permission problems in Symfony2.
I want Puphpet.com to handle that automatically too.
Is this possible?
I notice on https://puphpet.com/help that the section which mentions "Simply look inside your downloaded folder and open puppet/hieradata/common.yaml" may have something to do with it, but the folder I get after completing a config on puphpet.com doesn't have a common.yaml file in it.
The documentation is somewhat out of date, that file is now called config.yaml.
How to further configure it, say to tweak Apache settings (e.g. EnableSendfile Off), could use further elaboration on the tool's website. The project's lead commented on SO a couple months ago that updating the documentation was on his to-do list.

Why don't any functions run from the Doctrine 2.0 Command Line Interface (CLI)?

I've recently managed to get the betas of Codeigniter 2.0 and Doctrine 2.0 working together, thanks to the help from this guide: http://eryr.wordpress.com/2010/09/26/integrating-doctrine-2-with-codeigniter-2/
I have set up the CLI as set out in that guide, but I can't run any commands - I type doctrine and get the menu and list of commands, but then when I type a command like doctrine orm:schema-tool:create it just loads the same screen again with the list of commands. I don't get any error messages or anything.
My application/doctrine.php: http://pastebin.com/P0CtefhF
My application/cli-config.php: http://pastebin.com/KCVfZFct
If anyone can even give me a clue or point me in the right direction I would be most grateful. I have been trying to get my head around this for a day and a half now :S
Hey, I just got this all working together myself.
One thing, it depends on how you DL'd doctrine to begin with. I DL'd directly, no SVN or GIT in other words.
I ended putting my cli-config.php, doctrine.php and Doctrine.php in "application/tools" dir. "tools" is a dir I just created. It did not exist before.
The current way it's set up with the examples from that link you gave, I think they all need to be in "application/libraries", so if you want to move them to "application/tools" you need to update those paths.
So for example:
require_once CURPATH.'/../config/database.php';
This is saying to go up from 'application\tools' to 'application\config' and get that 'database.php' file.
require_once CURPATH.'/../libraries/Doctrine/Common/ClassLoader.php';
And This is doing the same, except that it is going into "application\libraries\Doctrine\Common" and looking for "ClassLoader.php"
Does that help?
Anyone having this trouble should try two things:
First of all instead of just typing doctrine command make sure you type php doctrine.php command.
Also make sure you have adjusted your system path correctly instead of your user account path.
Once I did both of those things it worked for me fine. Bit confusing though as the first command does work to bring up the list of possibilities, but not when you run any actual command.