[Bug 18564] New: kola-common.cnf parsing is too restrictive

classic Classic list List threaded Threaded
10 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[Bug 18564] New: kola-common.cnf parsing is too restrictive

bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18564

            Bug ID: 18564
           Summary: kola-common.cnf parsing is too restrictive
 Change sponsored?: ---
           Product: Koha
           Version: 16.11
          Hardware: All
                OS: All
            Status: NEW
          Severity: minor
          Priority: P5 - low
         Component: Installation and upgrade (command-line installer)
          Assignee: [hidden email]
          Reporter: [hidden email]
        QA Contact: [hidden email]

my koha-common.cnf is using this form:

[client]
host=db
user=root
password="move_rootpwd_to_dotenv"

this file is working has expected with mysql tools.

but koha-create parsing will not find the db host resulting in koha-conf.xml
containing no values in hostname element.

as a result trying to connect to the web serveur will raise an error :

Software error:

DBIx::Class::Storage::DBI::catch {...} (): DBI Connection failed: Can't connect
to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2) at
/usr/share/perl5/DBIx/Class/Storage/DBI.pm line 1490. at
/usr/share/koha/lib/Koha/Database.pm line 90
Compilation failed in require at /usr/share/koha/intranet/cgi-bin/mainpage.pl
line 31.
BEGIN failed--compilation aborted at
/usr/share/koha/intranet/cgi-bin/mainpage.pl line 31.
For help, please send mail to the webmaster ([no address given]), giving this
error message and the time and date of the error.

--
You are receiving this mail because:
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list
[hidden email]
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[Bug 18564] kola-common.cnf parsing is too restrictive

bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18564

--- Comment #1 from Eric Vantillard <[hidden email]> ---
adding spaces around the equal sign will resolve the issue

the problem is in kohl-create function getmysqlhost()

https://github.com/Koha-Community/Koha/blob/master/debian/scripts/koha-create#L124

the awk search require spaces

--
You are receiving this mail because:
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list
[hidden email]
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[Bug 18564] kola-common.cnf parsing is too restrictive

bugzilla-daemon
In reply to this post by bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18564

--- Comment #2 from Eric Vantillard <[hidden email]> ---
maybe something like that

awk '
BEGIN {
        FS="="
}
$1 ~/\[/ {
        inclient=0
}
$1 ~/\[client\]/ {
        inclient=1
        next
}
inclient==1 && $1 ~/host/ {
        print $2
}
' /etc/mysql/koha-common.cnf

--
You are receiving this mail because:
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list
[hidden email]
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[Bug 18564] koha-common.cnf parsing is too restrictive

bugzilla-daemon
In reply to this post by bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18564

Chris Cormack <[hidden email]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |[hidden email]
            Summary|kola-common.cnf parsing is  |koha-common.cnf parsing is
                   |too restrictive             |too restrictive

--
You are receiving this mail because:
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list
[hidden email]
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[Bug 18564] koha-common.cnf parsing is too restrictive

bugzilla-daemon
In reply to this post by bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18564

--- Comment #3 from Eric Vantillard <[hidden email]> ---
Created attachment 63501
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=63501&action=edit
patch changing the awk script

--
You are receiving this mail because:
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list
[hidden email]
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[Bug 18564] koha-common.cnf parsing is too restrictive

bugzilla-daemon
In reply to this post by bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18564

M. Tompsett <[hidden email]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |[hidden email]

--- Comment #4 from M. Tompsett <[hidden email]> ---
Is this patch ready to sign off?
I have an amendment to make. :)

--
You are receiving this mail because:
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list
[hidden email]
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[Bug 18564] koha-common.cnf parsing is too restrictive

bugzilla-daemon
In reply to this post by bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18564

M. Tompsett <[hidden email]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |Needs Signoff

--
You are receiving this mail because:
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list
[hidden email]
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[Bug 18564] koha-common.cnf parsing is too restrictive

bugzilla-daemon
In reply to this post by bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18564

--- Comment #5 from M. Tompsett <[hidden email]> ---
Created attachment 64557
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=64557&action=edit
Bug 18564: MariaDB doesn't have a debian.cnf file

The koha-common.cnf file is a link to debian.cnf, which MariaDB
does not install. This just forces a 'localhost' return value.

--
You are receiving this mail because:
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list
[hidden email]
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[Bug 18564] koha-common.cnf parsing is too restrictive

bugzilla-daemon
In reply to this post by bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18564

M. Tompsett <[hidden email]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           See Also|                            |https://bugs.koha-community
                   |                            |.org/bugzilla3/show_bug.cgi
                   |                            |?id=9409

--
You are receiving this mail because:
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list
[hidden email]
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[Bug 18564] koha-common.cnf parsing is too restrictive

bugzilla-daemon
In reply to this post by bugzilla-daemon
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18564

M. Tompsett <[hidden email]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |[hidden email]

--
You are receiving this mail because:
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list
[hidden email]
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/
Loading...