Hello. I have been assigned to help a large forum to convert to 2.0.1. I warned them that this will be a rough ride with lots of troubleshooting, and yet they still insisted on the convert. The forum in question is live, running and doing well, but there are some errors.
First, I will explain my upgrade procedure:
- I have downloaded the upgrade package
- Upgraded the forum successfully
- Saw that error logs were piling up with various errors - package related
- I have uninstalled and deleted all the packages
- A lot of errors were still appearing, but that was because of the theme modifications
- I have uninstalled ALL themes
- I have suspended access to the forum with htaccess
- Deleted Sources and Themes
- Copied the original 2.0.1 Sources and Themes
The error logs are now a lot more silenced... only a few errors remain which confuse me. I know they are somehow related to the previous forum configuration, but I have no idea how to troubleshoot this, since i'm not a php programmer
Examples:
User Dacha, time: 11:07:10, 3 messages, same error, different lines
Quote
xxforumrootxx/index.php?action=pm
8: Undefined index: name
Datoteka: /home/vwclub/public_html/forum/Themes/default/PersonalMessage.template.php
Linija: 625
xxforumrootxx/index.php?action=pm
8: Undefined index: name
Datoteka: /home/vwclub/public_html/forum/Themes/default/PersonalMessage.template.php
Linija: 620
xxforumrootxx/index.php?action=pm
8: Undefined index: name
Datoteka: /home/vwclub/public_html/forum/Sources/PersonalMessage.php
Linija: 363
User Shone190, time 07:46:09
Quote
xxforumrootxx/index.php?action=pm;f=inbox;l=-1;done=sent
8: Undefined index: name
Datoteka: /home/vwclub/public_html/forum/Themes/default/PersonalMessage.template.php
Linija: 466
xxforumrootxx/index.php?action=pm;f=inbox;l=-1;done=sent
8: Undefined index: nameDatoteka: /home/vwclub/public_html/forum/Themes/default/PersonalMessage.template.php
Linija: 466
xxforumrootxx/index.php?action=pm;f=inbox;l=-1;done=sent
8: Undefined index: name
Datoteka: /home/vwclub/public_html/forum/Themes/default/PersonalMessage.template.php
Linija: 466
xxforumrootxx/index.php?action=pm;f=inbox;l=-1;done=sent
8: Undefined index: name
Datoteka: /home/vwclub/public_html/forum/Themes/default/PersonalMessage.template.php
Linija: 466
... totaling 22 times from shone190
Basically the pattern is this:
On this link: xxforumrootxx/index.php?action=pm
I get this error: 8: Undefined index: name
On these lines: 363, 620, 625
On this link: xxforumrootxx/index.php?action=pm;f=inbox;l=-1;done=sent
I get this error: 8: Undefined index: name
On line 464, 466 - but it repeats various number of times (same second both lines, but 466 repeats)
I get other errors, all are somehow related to personal messages:
xxforumrootxx/index.php?action=pm;sa=pmactions;f=inbox;start=0
8: Undefined index: unread_messages
Datoteka: /home/vwclub/public_html/forum/Sources/PersonalMessage.php
...Undefined index: id, Undefined index: unread_messages, undefined_offset:0, Undefined_id ...
I am also a hosting linux administrator on the shared hosting machine this site is hosted on. Could you guys offer me some assistance?
I am willing to reset any and all previous 1.x plugin settings that were applied before upgrades if you think that this is what is causing it, but you will also have to tell me how to do it because I'm relatively new to SMF
Thank you!
When you make an upgrade to a forum all mods are uninstalled automatically.
Are there any mods installed on the forum after the upgrade?
Also attach the below mentioned files in next reply
- themes\default\PersonalMessage.template.php
- Sources\PersonalMessage.php
Thank you very much for your response Joker!
No packages are installed, and the forum still generates error messages.
As i said earlier: i have even tried copying the original smf 2.0.1 sources and themes folders, but it still generates same errors.
These two files are from my server. They should be exactly the same as smf 2.0.1 files
Bump, and a new error after enabling "Warn" builtin system
http://www.vw-club.rs/forum/index.php?action=profile;u=29526;area=issuewarning
2: sprintf() [<a href='function.sprintf'>function.sprintf</a>]: Too few arguments
File: /home/vwclub/public_html/forum/Sources/Profile-Actions.php
Line: 327
repeats often
Also: here is a list of disabled functions on our hosting provider:
allow_url_fopen, apache_child_terminate, apache_setenv, define_syslog_variables, escapeshellarg, escapeshellcmd, eval, exec, fp, fput, ftp_connect, ftp_exec, ftp_get, ftp_login, ftp_nb_fput, ftp_put, ftp_raw, ftp_rawlist, highlight_file, ini_alter, ini_get_all, ini_restore, inject_code, mysql_pconnect, openlog, passthru, php_uname, phpAds_remoteInfo, phpAds_XmlRpc, phpAds_xmlrpcDecode, phpAds_xmlrpcEncode, popen, posix_getpwuid, posix_kill, posix_mkfifo, posix_setpgid, posix_setsid, posix_setuid, posix_setuid, posix_uname, proc_close, proc_get_status, proc_nice, proc_open, proc_terminate, shell_exec, syslog, system, xmlrpc_entity_decode
P.S.
average user count at any time is 50-100
Sorry for a bit delayed response. Your files seems to be absolutely fine.
Does these errors appears on english language pack also (the default one which comes with smf)?
I will reply again in ~15 hours from now
I am setting the forum to English and resetting the error logs. You rock Joker!
Sorry for the doublepost. The errors are still there, no need to wait till morning
I had set the board so the users can't change their language, when setting the board to english before.
Example:
User: Madison, Time : 11:41:47
errors follow
xxxforumxxx/forum/index.php?action=pm;sa=send;pmsg=153339;u=22516;reply;wap2
8: Undefined index: unread_messages
File: /home/vwclub/public_html/forum/Sources/PersonalMessage.php
Line: 365
xxxforumxxx/forum/index.php?action=pm;sa=send;pmsg=153339;u=22516;
reply;wap2
8: Undefined index: idFile: /home/vwclub/public_html/forum/Sources/PersonalMessage.php
Line: 364
xxxforumxxx/forum/index.php?action=pm;sa=send;pmsg=153339;u=22516;reply;wap2
8: Undefined index: name
File: /home/vwclub/public_html/forum/Sources/PersonalMessage.php
Line: 363
xxxforumxxx/forum/index.php?action=pm;sa=send;pmsg=153339;u=22516;reply;wap2
8: Undefined index: id
File: /home/vwclub/public_html/forum/Sources/PersonalMessage.php
Line: 362
xxxforumxxx/forum/index.php?action=pm;sa=send;pmsg=153339;u=22516;reply;wap2
8: Undefined index: unread_messages
File: /home/vwclub/public_html/forum/Sources/PersonalMessage.php
Line: 359
xxxforumxxx/forum/index.php?action=pm;sa=send;pmsg=153339;u=22516;reply;wap2
8: Undefined index: id
File: /home/vwclub/public_html/forum/Sources/PersonalMessage.php
Line: 355
xxxforumxxx/forum/index.php?action=pm;sa=send;pmsg=153339;u=22516;reply;wap2
8: Undefined index: messages
File: /home/vwclub/public_html/forum/Sources/PersonalMessage.php
Line: 229
xxxforumxxx/forum/index.php?action=pm;sa=send;pmsg=153339;u=22516;reply;wap2
8: Undefined offset: 0
File: /home/vwclub/public_html/forum/Sources/PersonalMessage.php
Line: 229
and then they would repeat. not always in the same order, and not always all of them.
Edit: i have seen this one before too, I don't know if i had mentioned it. This one repats on line 1291 for the same file
xxxforumxxx/forum/index.php?action=pm;f=inbox;l=-1;done=sent;wap2
8: Undefined index: name
File: /home/vwclub/public_html/forum/Themes/default/Wireless.template.php
Line: 1291
xxxforumxxx/forum/index.php?action=pm;f=inbox;l=-1;done=sent;wap2
8: Undefined index: id
File: /home/vwclub/public_html/forum/Themes/default/Wireless.template.php
Line: 1291
Edit2 ^ updated this previous edit. undefined index id/name
And all of the error seems to be related to labels created for Personal messages.
Just curious to know does those errors appears with your profile too?
Have you created any labels so far for your PM's?
If answer to both of above question is no, then please create a label for your PM and see if error appears from profile too.
To create label -- Personal Messages » Manage Labels
I am pretty sure that it has happened with my profile too. Lets say "no" to both questions.
I have created a label "test"
i have went into my inbox and started labeling random pms
I don't see any errors so far. Would you like me to test some more?
Quote from: Kaurin on December 09, 2011, 08:07:37 AM
I am pretty sure that it has happened with my profile too. Lets say "no" to both questions.
I have created a label "test"
i have went into my inbox and started labeling random pms
I don't see any errors so far. Would you like me to test some more?
The lines pointed out in errors are related to PM's labels. Yeah for sure, try to send some PM to some other id(a dummy account of yours) and see if the error pops up.
Hmm... This is what I have tried:
Adding label test to random messages
Adding label test to all messages
Removing label test from random messages
Removing label test from all messages
Removing label "inbox" from all messages
Sending messages
Replying to messages (labeled and unlabeled)
So far - nothing.
Could you suggest what else to try regarding labels and PMs ?
Quote from: Kaurin on December 09, 2011, 10:51:07 AM
Hmm... This is what I have tried:
Adding label test to random messages
Adding label test to all messages
Removing label test from random messages
Removing label test from all messages
Removing label "inbox" from all messages
Sending messages
Replying to messages (labeled and unlabeled)
So far - nothing.
Could you suggest what else to try regarding labels and PMs ?
Wow this getting way more confusing then what I thought of.
Umm whats the member group of the members who were able to generate those errors? Try the same test having there member group on the dummy account.
One more thing can you check the label column in database for those member (if you are comfortable with it) ad post the result here.
prefix_members (replace prefix with the prefix you have used for your forum)
P.S - I'm pretty sure fix is going to be a very easy one :P.
Most of the members are from the group "Uprava Kluba" (Club management), but it is because they PM each other often (my guess). They hang out on the forums a lot, almost constantly online.
But i have just seen another one showing up who is just a "Junior Member" - ~200 posts
I have created a dummy account with a primary group of "Uprava Kluba", tried troubleshooting with the above tests, and i did not show up in the logs.
I am comfortable with phpmyadmin :) There is no column "labels" but there is "message_labels" None of those error msg members have any labels set
edit:
i have just sorted the smf_members table by "message_labels"
only 6 members have labels. I see that there is one member who has this label: "[URL=http://img441.i"
I am not touching it for now.
Quote from: Kaurin on December 09, 2011, 01:14:29 PM
Most of the members are from the group "Uprava Kluba" (Club management), but it is because they PM each other often (my guess). They hang out on the forums a lot, almost constantly online.
But i have just seen another one showing up who is just a "Junior Member" - ~200 posts
I have created a dummy account with a primary group of "Uprava Kluba", tried troubleshooting with the above tests, and i did not show up in the logs.
Meh, so we got a issue which we can't replicate.
QuoteI am comfortable with phpmyadmin :) There is no column "labels" but there is "message_labels" None of those error msg members have any labels set
Lol, I was in a bit of hurry so must have mistyped it.
Quote from: Kaurin on December 09, 2011, 01:14:29 PM
edit:
i have just sorted the smf_members table by "message_labels"
only 6 members have labels. I see that there is one member who has this label: "[ URL=http://img441.i"
I am not touching it for now.
Again a very basic question, out of these 6 members has anyone produced the concerning error in error log?
One of them is me, and i have not seen any of the 5 in any of the error logs.
I have reset the logs around 4 hours ago
I will list the members showing now:
GTI 16V
Madison (this guy shows up a lot)
pokemoni (this guy shows up a lot)
Arsinov
None of them use labels
Administration Center » Forum Maintenance » Routine
Find and repair any errors
Recount all forum totals and statistics
Empty out unimportant logs
Empty the file cache
Clear your error log and run all of the above mentioned tasks. See if the errors still appears.
All right. Done. Will keep you posted in about few hours
still appearing :(
Hmm, I've made a post to know the views of other team members too.
ok while making a reply someone a vague code came to mind :P.
This is just a test code to see the root of the issue.
As you have mentioned above that you are getting errors at
Line: 466, PersonalMessage.Template.php
Go to themes\default\PersonalMessage.template.php (Make backup of file before editing it)
if (!$message['fully_labeled'])
{
echo '
<option value="" disabled="disabled">', $txt['pm_msg_label_apply'], ':</option>';
foreach ($context['labels'] as $label)
if (!isset($message['labels'][$label['id']]))
echo '
<option value="', $label['id'], '"> ', $label['name'], '</option>';
}
if (!$message['fully_labeled'] && !empty($context['labels']))
{
echo '
<option value="" disabled="disabled">', $txt['pm_msg_label_apply'], ':</option>';
foreach ($context['labels'] as $label)
if (!isset($message['labels'][$label['id']]))
echo '
<option value="', $label['id'], '"> ', $label['name'], '</option>';
}
Done. I will empty the error logs and report further
Still happening :(
Quote from: Kaurin on December 13, 2011, 11:09:12 AM
Still happening :(
Please post the errors here.
Meh, weirdness continues :P.
xxxforumxxx/forum/index.php?action=pm;f=inbox;sort=date;start=80
8: Undefined index: name
Datoteka: /home/vwclub/public_html/forum/Themes/default/PersonalMessage.template.php
Linija: 466
x1000 (not literally)
TBH, I'm starting to run out of options as only very few (6 ?) users are generating the concerning error. Also I'm not able to produce the error anyhow.
Lets try one more thing,
Download the large upgrade pack and reupload all of the language files once again.
Overwritten, will get back to you later. I have cleaned the logs
I will report tomorrow morning
Edit:
Could this be a source of the problem (check attach)?
Even though users are not permitted to change the language, somehow ~500 of them still use Serbian!
Edit2:
DamirK
95.180.104.150
Today at 08:31:00 AM
0a9b798d891ed7e5e2e234270fc8ef53
Type of error: Undefined
http://www.vw-club.rs/forum/index.php?action=pm
8: Undefined index: name
File: /home/vwclub/public_html/forum/Themes/default/PersonalMessage.template.php
Line: 466
x1000 (not literaly)
This user generates most of these messages. He is one of the admins. There are still 586 users using Serbian. Should I ask him what language does he see the forum in?
Just a very quick question before I start making tests again on my local install.
Is your forum running on UTF-8? As in the screen shot one languages is UTF-8 and other is ISO (I might be wrong this time as I get lost when it comes to languages, but worth a try).
Please try to put your forum on the same character encoding once.
Database was in latin1_swedish (which is weird, because Serbian characters are not in that collation). After converting the database to UTF8, characters remained OK
I cleared the log, set the language to Serbian.UTF8 (3 members remained in English somehow... :/ )
Waited
Still happening :/
Go to the following address in your forum and try to make the changes
yourofrumaddress.com/index.php?action=admin;area=languages;sa=settings
Whenever i wrote "i have set language X to be default" i ment those options. I always disable users from changing the language while in this testing phase
Quote from: Kaurin on December 14, 2011, 04:19:22 PM
Whenever i wrote "i have set language X to be default" i ment those options. I always disable users from changing the language while in this testing phase
Ohh ok. I told that option as you said still some users were able to use the Siberian language pack.
Umm lets summarize this topic so far
1. Users are generating errors in following files
- Sources\PersonalMessage.php -> Line No. -- 365, 364, 363, 362, 359, 355, 229
- Themes\PersonalMessage.template.php -> Line No. -- 625, 620, 466
- All errors a getting generated due to the code written for labels.
2. Forum is one UTF-8 and right now using English language pack (You have Siberian pack installed as well).
3. Forum version is 2.0.1 and no mods installed.
4. Only 6 members are making use of labels feature and none has produced any error so far.
5. Users who have generated the concerning errors are:
- GTI 16V
- Madison (this guy shows up a lot)
- pokemoni (this guy shows up a lot)
- Arsinov
- DamirK
Can you provide me a test account? In the mean time I'm going to try to produce the errors your forum has generated so far.
Serbian, not Siberian xD
1.
yes
yes
i dont know
2
yes
3.
yes
4.
yes
5.
yes, and some other pop up occasionally. users listed are very active
I have some disobedient admins who installed and deinstalled some plugins. Currently, there are 0 plugins installed, and i have again overwritten .php files with the theme original files just to be sure.
I have overwritten the following:
Sources
Themes/default
Themes/default/js
Themes/defaultlanguages
I have also overwritten your changes in themes\default\PersonalMessage.template.php
If you need me to put back your edit, let me know
I am sending you the credentials via pm
Joker is the man. I don't want to get in the way. but I remember having an issue like this where only a few selected members were producing errors on certain pages, that me, or other members couldn't reproduce. What I did, was search the member's id ( the ones producing the errors) in phpMyAdmin under smf_members ... and checked their language setting.
Sure enough, they were set to a language that wasn't the forum set default. This happened after an upgrade, as well.
Not sure if that's a solution, but worth checking out.
hcfwesker, I should try doing that either way. I will summon the powers of sql shenanigans, and set the default language for all member. I just want to wait for a green light from Joker
Btw.. no errors (except wrong password, waiting admin approval etc)
you dont need to use a query to set the default language for all users admin -> languages -> settings default forum language that should reset the default for everyone i believe.
Illori: that is exactly the issue. Using that cannot change the language for everyone. Setting the language to "English" for everyone leaves ~500 users with Serbian, and Setting the language to Serbian for everyone leaves 3 users with English
do you also have the default language on the main language page set as english?
Right now: Yes
I am not sure that this was the case before though!
Could the errors have anything to do if the 1st and 3rd page of the language settings have different languages set?
Still waiting for joker's opinion before I try anything
Logs clean
if it is an issue with your language files it is possible, but we are not sure.
I await further instructions
Thank you for pitching in guys!
Quote from: Kaurin on December 15, 2011, 05:34:30 AM
I await further instructions
Thank you for pitching in guys!
Ok logged in the forum and sent a message to myself (hehehe). Kaurin see if my user account was able to produce any error.
Quote from: hcfwesker on December 15, 2011, 01:32:06 AM
Joker is the man. I don't want to get in the way. but I remember having an issue like this where only a few selected members were producing errors on certain pages, that me, or other members couldn't reproduce. What I did, was search the member's id ( the ones producing the errors) in phpMyAdmin under smf_members ... and checked their language setting.
Sure enough, they were set to a language that wasn't the forum set default. This happened after an upgrade, as well.
Not sure if that's a solution, but worth checking out.
Wow how come I missed that :P.
Quote from: Kaurin on December 15, 2011, 04:22:57 AM
hcfwesker, I should try doing that either way. I will summon the powers of sql shenanigans, and set the default language for all member. I just want to wait for a green light from Joker
Go for it sir. Make the database backup first and perform the required changes.
Also one of the team has has suggested that just make sure that you are using SMF 2.0.1 Siberian language pack.
Let me double check what you want me to do:
Set forum language to Serbian on both language settings
Update the database
correct?
edit:
no error messages from Joker. Standard error messages started occurring again from various members
Quote from: Kaurin on December 15, 2011, 08:08:45 AM
Let me double check what you want me to do:
Set forum language to Serbian on both language settings
Update the database
correct?
edit:
no error messages from Joker. Standard error messages started occurring again from various members
Things we want you to do
- Check whether the Siberian language pack you are using is SMF 2.0.1 Siberian language pack.
- Make the backup of database
- Update the database and set everyone to english
I will report within a few hours. I apologize in advance for the doublepost :)
One of the most-appeared members in the logs is DamirK, one of the admins
I have asked him to go into his PM section and click around. He generated ~150 errors within a minute. Same errors as always
What's our next course of action?
Kaurin well right now I'm out of ideas, but as you said yourself that a very few users are generating this error so it has something to do with their settings etc.
They may be using a different
- theme,
- language or
- pm setting
The guys from the forums are thinking about disregarding those messages and maybe turning off the logs, or reduce the pruning to 3 days. :(
Forum itself is not generating any increased load on our shared hosting machine, or giving me any other headaches. As far as I'm concerned, their decision is fine with me, but I might check back now and then to their forum to try out some other solutions.
I want to thank you guys for trying to help! As for this thread, it might be best to keep it open in case I find a solution.
Thanks again!
Quote from: Kaurin on December 16, 2011, 02:48:36 AM
The guys from the forums are thinking about disregarding those messages and maybe turning off the logs, or reduce the pruning to 3 days. :(
Don't turn off the logs as they might come handy in other issues (I hope you don't get anymore)
QuoteForum itself is not generating any increased load on our shared hosting machine, or giving me any other headaches. As far as I'm concerned, their decision is fine with me, but I might check back now and then to their forum to try out some other solutions.
I want to thank you guys for trying to help! As for this thread, it might be best to keep it open in case I find a solution.
Thanks again!
Umm ask the other admin to make a dummy account with same settings as his original account and see if the dummy account also generates the error.