Modify ↓
Opened 9 years ago
Closed 8 years ago
#12698 closed enhancement (wontfix)
Using ~/.my.cnf instead of Database connection string
| Reported by: | Owned by: | ||
|---|---|---|---|
| Priority: | normal | Milestone: | |
| Component: | general | Version: | 1.2 |
| Severity: | normal | Keywords: | |
| Cc: | Branch: | ||
| Release Notes: | |||
| API Changes: | |||
| Internal Changes: | |||
Description
On FreeBSD, I try to backup enviroment:
# trac-admin path/to/enviroment hotcopy path/to/backup Hotcopying path/to/enviroment to path/to/backup ... Backing up database ... TracError: mysqldump failed: mysqldump: Got error: 1045: Access denied for user 'trac'@'localhost' (using password: YES) when trying to connect
When I remove (rename) ~/.my.cnf which describes some other MySQL user, not 'trac'@'localhost' (who is the only one having access to Trac's database), hotcopying succeeds.
trac-admin should prefer data in Database connection string, not in ~/.my.cnf.
Attachments (0)
Change History (3)
comment:1 by , 9 years ago
comment:2 by , 8 years ago
There's no read_default_file in my project's trac.ini and parameters in [inherit] section are empty.
trac-admin ends with error when:
- FreeBSD user, who has run it, has
.my.cnfin his home directory, and - MySQL credential specified there has no access to Trac's database.
comment:3 by , 8 years ago
| Resolution: | → wontfix |
|---|---|
| Status: | new → closed |
| Type: | defect → enhancement |
read_default_file is in database connection string.
Note:
See TracTickets
for help on using tickets.



No. Trac Environment, tracd, trac-admin, … shouldn't depend on
$HOME/.my.cnffile (Whose home directory? root? apache? someone?). Useread_default_fileparameter if you want to use.my.cnf. See DatabaseBackend#MySQL.However,
mysqldumpvia hotcopy have to work even if ~/.my.cnf is existent or not.