Project

General

Profile

Actions

Bug #26939

closed

ActiveRecord::ValueTooLong: PG::StringDataRightTruncation: ERROR: value too long for type character varying(255)

Added by Kyle VonBlohn almost 5 years ago. Updated almost 5 years ago.

Status:
Closed
Priority:
High
Category:
Database
Target version:
-
Difficulty:
Triaged:
No
Fixed in Releases:
Found in Releases:

Description

This appears to only be an issue with windows systems. When editing, building, or canceling build, it fails with the following error:

2019-06-03T11:42:05 [W|app|c38e7b37] Rolling back due to exception during save
ActiveRecord::ValueTooLong: PG::StringDataRightTruncation: ERROR: value too long for type character varying(255)
: UPDATE "hosts" SET "build" = $1, "initiated_at" = $2, "updated_at" = $3, "root_pass" = $4, "grub_pass" = $5 WHERE "hosts"."id" = $6
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql_adapter.rb:603:in `async_exec'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql_adapter.rb:603:in `block (2 levels) in exec_no_cache'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/dependencies/interlock.rb:48:in `block in permit_concurrent_loads'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/concurrency/share_lock.rb:187:in `yield_shares'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/dependencies/interlock.rb:47:in `permit_concurrent_loads'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql_adapter.rb:602:in `block in exec_no_cache'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract_adapter.rb:579:in `block (2 levels) in log'
/opt/rh/rh-ruby25/root/usr/share/ruby/monitor.rb:226:in `mon_synchronize'
...

This happens with a root password of 8 characters. If I edit the config and simply retype the same 8 character password, everything will work fine for the next operation I perform, then the error will appear again. I am Thoroughly confused on this. I have seen similar errors reported with older versions of Foreman, but they appear to have been fixed. Again, this only happens with my windows hosts, Linux hosts never have this issue. Any help would be greatly appreciated. The full error snippet from the log file is attached. I am relatively new with foreman so let me know if I need to provide additional information.

Thanks


Files

Foreman-error.txt Foreman-error.txt 36.2 KB Kyle VonBlohn, 06/03/2019 03:51 PM
Actions #1

Updated by The Foreman Bot almost 5 years ago

  • Status changed from New to Ready For Testing
  • Assignee set to Lukas Zapletal
  • Pull request https://github.com/theforeman/foreman/pull/6819 added
Actions #2

Updated by Tomer Brisker almost 5 years ago

  • Category set to Database
  • Fixed in Releases 1.23.0 added
Actions #3

Updated by Lukas Zapletal almost 5 years ago

  • Status changed from Ready For Testing to Closed
Actions

Also available in: Atom PDF